Spatial Join ERROR 001156

08-04-2016 09:16 AM
Regular Contributor

Trying to do a spatial join with two layers but i keep getting the following error. When i look up the error 001156 it indicates that the field length my not be long enough but the FZone_Code field mapping length is set to 60, so i am not sure what' it's not working, the longest attribute i have in the FZ is 12 characters long (AG/ComComRes) It should fit right? there is also a few NULL attributes.

Any help would be great, thanks.

Traceback (most recent call last):

  File "C:\GIS\Python\\", line 149, in <module>

    arcpy.SpatialJoin_analysis(FZon1, UG, "In_memory\UG1", "JOIN_ONE_TO_ONE", "KEEP_ALL", Layers2(FZon1,UG), "HAVE_THEIR_CENTER_IN")

  File "C:\Program Files (x86)\ArcGIS\Desktop10.2\arcpy\arcpy\", line 461, in SpatialJoin

    raise e

ExecuteError: ERROR 001156: Failed on input OID 20670, could not write value 'AG/ComIndInd' to output field FZONE_CODE

Failed to execute (SpatialJoin).

never mind I called Fzone field twice and that's why i was getting the error. my bad.

0 Kudos
0 Replies