Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have a coded domain field with 10 dropdown options. Possible choices include integers and text.

I need to change a selection of 250 features (which have differing values) to the same value. This value is one of the dropdown values.

When I use the field calculator (field="value") I get an error. The calculated value is invalid.....

Anyone know how to change multiple values within a coded domain field?

enter image description here

share|improve this question
4  
Are you calcing in the actual string value or the coded value? So if for example, 1 = "foo", I'm thinking you are needing to calc in the 1, and not "foo". –  Chad Cooper Mar 18 '13 at 14:02

1 Answer 1

It will depend somewhat on the type of field and domain you are using.
Assuming you are using the defaults, integer, and coded value.
you want the syntax in the field calculator to be (selectedrowsinmydomainfield) = newcodedvalue in the example...
Pic1
nom_size is the domain with 1 = 1"
If I want to change all selected values to 1".
I use the syntax in the middle ( [nom_size] = 1
If you are using text field with a text domain.

EDIT:
Ok since you are using a text domain and your codes all match your descriptions.
If you want to change all selected rows to be BETH.
[ZONE_] = "BETH"

share|improve this answer
    
Possible choices include integers and text. –  Thad Mar 18 '13 at 15:44
    
you want to match that (the domain type) to the field type you are applying it to. Are you using text or int? the benefit to text (there are drawbacks) is that you can make the code exactly the same as the description (what displays in attribute). –  Brad Nesom Mar 18 '13 at 15:48
    
text. I added an image which might make things more clear. –  Thad Mar 18 '13 at 15:52
    
re: EDIT, yes that is what I have been trying. But I'm getting the error "The calculated value is invalid....." –  Thad Mar 18 '13 at 17:26
    
(field="value") is incorrect. you need the field name in braces and the value in double quotes. The parenth can be there if your field name is in braces (but not required) –  Brad Nesom Mar 18 '13 at 17:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.