Reorder and rename fields in ArcGIS
#1
Posted 30 April 2008 - 08:33 AM
Does anyone knows how to reorder and rename fields of shapefiles in Arc? We have clients that have really strict specifications and we need to do that for them without, if possible, having to create new files everytime.
Thanks!
Francois Goulet
---
www.fgcartographix.com :: blog.fgcartographix.com :: http://twitter.com/fgcartographix
#2
Posted 30 April 2008 - 08:49 AM
If I need to do substantial edits I do it in excel.
Cartographer, Bureau of Land Management
Oregon State Office
Portland, Oregon
pfyfield@blm.gov
#3
Posted 30 April 2008 - 08:57 AM
Red Geographics
Email: hans@redgeographics.com / Twitter: @redgeographics
#4
Posted 30 April 2008 - 09:34 AM
There are two ways I commonly do this. One is to add new fields with the names and in the order that I want and use the field calculator to copy the attributes over from the fields I don't want, then delete them. This is clearly not ideal.
If I need to do substantial edits I do it in excel.
Unfortunately I believe this is what you have to do if your working with shp files. How about using feature classes instead? You should be able to modify the names directly in MS Access if you went that route. Someone correct me if I'm wrong. You could also download the XTools trial. They have a tool called "Table Restructure" but I don't know the specifics on it. So who knows.
With the field names could you get away with assigning an alias? Check out XTools
#5
Posted 30 April 2008 - 10:12 AM
Unfortunately I believe this is what you have to do if your working with shp files. How about using feature classes instead? You should be able to modify the names directly in MS Access if you went that route. Someone correct me if I'm wrong. You could also download the XTools trial. They have a tool called "Table Restructure" but I don't know the specifics on it. So who knows.
With the field names could you get away with assigning an alias? Check out XTools
I did it often when I was working in geodatabase, but we have to work with shapefile exclusively...
I had XTools and it works well. It create a new file, but I can live with that but if I may... any free tools to do that? (I just don't have to be the one to always do those operations
Thanks Erin!
Francois Goulet
---
www.fgcartographix.com :: blog.fgcartographix.com :: http://twitter.com/fgcartographix
#6
Posted 30 April 2008 - 12:05 PM
Mapping Center Answer:
First, there's now way to rename fields. So you have to create a new field and calculate it to have the values of the old field, which for a one-off problem is likely faster.
But if the shapefile has a number of such problems, there's no way to do this without creating a new shapefile. But, the new shapefile could replace the old one. Here's how I would do this. Create a Geoprocessing model that creates a new empty feature class and then sequentially adds the fields in the correct order using the Add Field tool. It is very important to exactly match all the properties of these fields to your original dataset's fields (the name may need to be changed. Then use the Append tool with your original feature class as the input dataset and your empty feature class as the target dataset. Note that you can use the field mapping part to deal with mis-named fields.
Now you have a model that you can run anytime you receive non-conforming data for this client.
I still think it should be easier to do it... MapInfo do it quite well! (that last comment was just to tickle them
Francois Goulet
---
www.fgcartographix.com :: blog.fgcartographix.com :: http://twitter.com/fgcartographix
#7
Posted 30 April 2008 - 12:28 PM
MapInfo do it quite well! (that last comment was just to tickle them
)
Yep, you can do this in Mapinfo with one hand tied behind your back and one eye closed!
#8
Posted 30 April 2008 - 04:08 PM
For tasks that you may need to repeat, you can also script things in e.g. python.
#9
Posted 30 April 2008 - 04:50 PM
Why make it hard for yourself - just open the .dbf file in excel and go nuts at it! (rename, reorder etc)
Well I guess I wanted to it while editing my files because it's when I need to do it
Francois Goulet
---
www.fgcartographix.com :: blog.fgcartographix.com :: http://twitter.com/fgcartographix
#10
Posted 30 April 2008 - 05:22 PM
Why make it hard for yourself - just open the .dbf file in excel and go nuts at it! (rename, reorder etc)
Well I guess I wanted to it while editing my files because it's when I need to do it... and because Excel 2007 doesn't save in .dbf anymore
I'll try some dbf editor from the Web...
Open Office!
#11
Posted 30 April 2008 - 06:47 PM
GIS Manager/Chief Cartographer
Ecotrust
#12
Posted 30 April 2008 - 07:32 PM
but than again I'm a Manifold user, & my Arc knowledge is a bit back at 8.3
#13
Posted 01 May 2008 - 01:24 AM
#14
Posted 01 May 2008 - 07:39 AM
I really like XTools when working with shapefiles within an arc environment. It may be over $100, but if your an ESRI'er, it has many other tools (eg recalcing area and length, etc) that make GIS life much more pleasant.
As of ArcGIS 9.2 calculating area and length are part of the core product. Just right click on your field and select calculate geometry. I am so glad ESRI added this.
Rich
#15
Posted 01 May 2008 - 12:12 PM
I really like XTools when working with shapefiles within an arc environment. It may be over $100, but if your an ESRI'er, it has many other tools (eg recalcing area and length, etc) that make GIS life much more pleasant.
As of ArcGIS 9.2 calculating area and length are part of the core product. Just right click on your field and select calculate geometry. I am so glad ESRI added this.
Rich
so true! back in the day i would convert my edited shapefile to a coverage so i could get recalced area, create a new "acre" field, and then do a math calculation just to populate the field. then, after all of that, i would have to reconvert the coverage back into a shapefile for my clients. ESRI's move from coverage to gdb was pretty painful from 8.2-9.0. I did that a couple of times before I just went back to the command line environment and edited coverages in arcedit. ArcMap gui is nice, but I still marvel at how much good stuff was left behind and is only now resurfacing. Most commonly in the toolbox, but it's a rare pleasure when it's only a right mouse click away!
a
GIS Manager/Chief Cartographer
Ecotrust
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users


Sign In
Create Account

Canada
Back to top
United States
Netherlands

Sweden
No Country Selected









