Hello! New on the forum and not an expert on GIS, and thats why I'm here. I have a problem where I would like to create a new column in an attribute table that I have. It has over 800 posts and I would like to create a new column with simple values (1-10) based on another column with text named "geology". The geology column contains values like "stone" "silt" "clay" and so on, so there are many fields containing the same values. I would like the new column to have all the stone fields in the geology column to have the value 1 in the new, silt 2 and so on. More or less converting the explanatory geology text column into a new column with values representing the different coverages. Is there a tool for it or do I have to struggle with coding which I am very new to? Thanks in advance! /Björn Turegård
What you can do is use the Dissolve tool on the Geology field, then in the output, create a new field and number the different types however you need them. Then, join this new table back to your original data.
You can also look into domains, which are used to enforce data integrity by using code values to describe other values. First, create a new file geodatabase, if the data isn't already stored in one and import your shapefile into it. From your dissolved output, export the attribute table to a standalone table. Then, use the Table to Domain tool and fill out the table accordingly. Finally, set the new text field you have to use the domain you just created.
What you can do is use the Dissolve tool on the Geology field, then in the output, create a new field and number the different types however you need them. Then, join this new table back to your original data.
You can also look into domains, which are used to enforce data integrity by using code values to describe other values. First, create a new file geodatabase, if the data isn't already stored in one and import your shapefile into it. From your dissolved output, export the attribute table to a standalone table. Then, use the Table to Domain tool and fill out the table accordingly. Finally, set the new text field you have to use the domain you just created.