laptop and a wrench

Bug

A searchcursor will cause PythonWin and Idle to crash when used with Add Field in a File Geodatabase.

Zuletzt veröffentlicht: August 25, 2014 No Product Found
Bug-ID-Nummer NIM006126
EingereichtJanuary 17, 2007
Zuletzt geändertApril 2, 2025
Gilt fürNo Product Found
Gefunden in Version9.2
StatusWill Not Be Addressed

Zusätzliche Informationen

We apologize that we were unable to address this issue within the current product support cycle. If the issue continues to affect your work in a supported release, please contact Technical Support.

Workaround

This sample stores all the OID's in a python list while in the cursor, and then accesses the list and adds the fields after the cursor has been put to bed.#~~~~~~~~rows = gp.searchcursor(fc)row = rows.next()OIDList = []while row: OIDList.append(row.OBJECTID) row = rows.next()del rowdel rows for OID in OIDList: gp.AddField_management(fc, "TK" + str(OID), "TEXT", "", "", "", "", "NULLABLE", "NON_REQUIRED", "") #~~~~~~~~

Schritte zur Reproduzierung

Bug-ID: NIM006126

Software:

  • No Product Found

Benachrichtigung erhalten, wenn sich der Status eines Bugs ändert

Esri Support App herunterladen

Weitere Informationen zu diesem Thema erkunden

Unterstützung durch ArcGIS-Experten anfordern

An den technischen Support wenden

Esri Support App herunterladen

Zu Download-Optionen wechseln