I'm experimenting with taking fields from an Excel file and importing them into a new feature class.
I understand that the field names you have in the Excel file will transfer over to the field names in the feature class, but what about data types and field properties? Is there something I can setup in my Excel table (or maybe a text file is better) that when I import data into a new feature class, the field name, data type, and field properties are already setup in the new feature class?
I'm working in this dialog box if it helps:
Thanks!
Edit:
Our DB Administrator is requiring certain fields that must go into any new feature class we make. There are 11 fields with specific data types and properties. Instead of manually entering those into the new feature class dialog box, I would like to import them.
In Excel, can we set something up where the field types and properties (in addition to the field names) would transfer over during the import?
Um that isn't exactly what I'm looking for...I can provide more context.
Our DB Administrator is requiring certain fields that must go into any new feature class we make. There are 11 fields with specific data types and properties. Instead of manually entering those into the new feature class dialog box, I would like to import them.
In Excel, can we set something up where the field types and properties (in addition to the field names) would transfer over during the import?
Does that make sense?
the field names get ported over if they are the first row on the sheet. The data type will only get transferred over once it reads some data.
You can 'fake' a file with one line of sample data representing the data types. forget formatting beyond the data type level, that isn't going to happen
It sounds like you have been pointed in the direction of a database designer's tool (such as X-Ray for ArcCatalog). Your DBA probably already has such tools, which might let you work with Excel. Your DBA should also have tools to check that you are complying with the standards.
But if you are not responsible for proving you are compliant, then I think your problem is much simpler. Set up a standard schema and import it in each new feature class. then tweak your extra fields in manually or using the Add Field or Alter Field GP tools. Or start from your extra fields and use Add Field to get the 11 fields.
Are you working in ArcMap, or in ArcPro? If you're working in ArcMap, check out X-Ray for ArcCatalog. If you're working in Pro, there currently is no X-Ray equivalent at the moment, but there is an idea for X-Ray in ArcPro that you could vote for.
X-Ray allows you to do this. I would still recommend mocking up your "base" feature class - one that has all the standard fields you'd be adding to every feature class - in ArcMap or ArcCatalog. Once you have that, you could use X-Ray to interrogate it, create a data dictionary and several Excel spreadsheets that you can use to update the schema. At that point, you can make updates - adding new fields, specifying the data type and other properties (like field length, for text fields, etc.) in the Excel. Then you'd save it, and import that new schema to a blank File Geodatabase.
If you're using ArcMap and want more information about how to do this, don't hesitate to ask. I use X-Ray a lot for developing and modifying schema.
Hey Jennifer.
Thank you for the X-Ray suggestion! I've been playing around with it and was curious about a few things.
So I've created those several Excel files and now would like to bring them into a blank geodatabase. Do I need to save the individual Excel files to XML format before importing the scheme to a file geodatabase? If so, which file format do you use? Essentially once you have these Excel files created, what is your process of updating and maintaining them to then bring into a new geodatabase when needed?
A couple of other options.
1) create a "default" feature class with all the needed fields and copy this as a starting point for all your new feature classes
2) you could build a script tool to add the 11 fields with specific data types and properties to a new feature class. A great example is the Add GPS Metadata Fields—Data Management toolbox | ArcGIS Desktop tool used to add the 16+ GNSS fields to a new feature class before publishing.