I have a field with similar values:
myField
JCH Corn
JCH Carrot
JCH Apple
ME/Orange
I would like to populate a new field depending on the value:
if myfield="JCH Corn" myNewField="Corn"
if myfield="JCH Carrot" myNewField="Carrot"
if myfield="JCH Apple" myNewField="Apple"
if myfield=ME/Orange" myNewField="Orange"
myNewField
Corn
Carrot
Apple
Orange
I was thinking I could do an eval if value statement, but I am not sure what is best in this situation.
Thanks!
| rex field=myField "\w+(\s|\/)(?<myNewField>\w+)"