Select to view content in your preferred language

Editing string value

1650
2
06-18-2013 05:05 AM
AndrewAidt
New Contributor
I'm trying to edit a string value field with a length of 50. It contains text. Examples are Curb Inlet, Manhole, and Outlet Pipe. I have miss spellings in this field and would like to edit them. When I try I get an error: "This Field must contain a string value." Now I am stuck and cannot get the error to go away. Even if I undo the edit the error window stays. I am using an Advanced license and the data is in a File Geodatabase.
Tags (2)
0 Kudos
2 Replies
MarkBoucher
Regular Contributor II
Here are some ideas:

Create a new field with the data type and length you want. Using field calculator make the new field equal to the contents of the old field. Confirm the copy was successful and delete the old field. See if that doesn't get around the editing problem. If the field needs to have a specific name create a field with the right field name, and copy the text there and delete the other (temp) field.

Spell checking: You can use other tools for spell checking. Below is the "hard way". (I've heard that one can set ArcMap up to use the MS Word spell checker, but I've never gotten far with that and I don't know if that goes beyond checking annotations.)

  1. Make a backup of your feature class (just in case).

  2. From the attribute table, export the table to a txt file.

  3. Open the txt file in Excel using commas separated option for the text to columns.

  4. Make sure the sort on the OID, Object ID field is sequential so you can make sure the sorted order in Excel matches that in ArcMap. If not, you can make a new column in Excel and put in sequential numbers (fill series) so you can resort back to the original order.

  5. Use the Excel spell checking and filtering tools to correct misspellings.

  6. Make sure the rows are sorted in Excel correctly as mentioned in step 4.

  7. Select the data in Excel without the column heading, and copy the column (not the entire table) you want to put back into ArcMap.

  8. In ArcMap, add a new field with the correct type and length (eg. text with 50 columns).

  9. Edit the feature class.

  10. Make sure the attribute table sort order in ArcMap has not changed.

  11. Put the cursor in top cell of the newest column in the attribute table.

  12. Right Click and Paste. This should paste the corrected text back into the attribute table.

  13. Check that the corrected field data corresponds to the right rows in the table.

  14. Modify the table (delete columns, etc). to meet your needs.

0 Kudos
JerryRing
New Contributor II

I also have this issue, but I was able to fix it on my end. In my situation, I had set a domain (string value) for the text field. Which really is redundant, a text field that has a domain assigned to it which is also a text field...no idea why I did this. I removed the domain assigned to the text field and the problem simply went away. Hope this helps.

0 Kudos