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.

Sometimes I have the need to copy a domain(s) from one geodatabase to another (without the featureclass or table).

In the past, I have accomplished this in a few different ways, but each method is not as straightforward as I think it could be (or maybe there's a CopyDomain tool that I've missed).

What method do you use to accomplish this?

share|improve this question
    
I know of at least 2 additional methods: maybe not "accepted answer" worthy, but definitely reputation worthy. I'll post them in a few days if no one else provides them as answers. –  Jay Cummins Nov 12 '10 at 13:10
    
Do post the additional solutions, the community will vote up if they are worthy :) –  MathiasWestin Nov 13 '10 at 13:58
    
On several occasions I've had to explain to non-GIS DBA's how domains are like a table, but are not stored as a table that can be accessed through SQL. Maybe answers to this should be in language a non-GIS DBA can understand. –  Kirk Kuykendall Nov 15 '10 at 15:24

5 Answers 5

up vote 7 down vote accepted

http://arcscripts.esri.com/details.asp?dbid=14729

This is an ArcCatalog Extension that allows you to copy domains between geodatabases.

I believe it is only up to date for 9.3.1 SP1, so it may not work with ArcGIS 10.

share|improve this answer
    
+1 I am on ArcGIS 10, but I deliberately left the question open to any version. I did get the 9.3.1 extension to work in ArcCatalog 10. I didn't get the new command on the context menu, but I was able to add the command to a toolbar and use it that way. –  Jay Cummins Nov 10 '10 at 15:14
    
Ok, glad that worked. You should let the extension author know about the context menu command not working in ArcCatalog 10. –  Seth P. Nov 10 '10 at 15:21
    
I did notify the author (crickets so far). Also, I applied SP1 to ArcGIS 10 on friday. Now the copy domains arccatalog extension errors when ArcCatalog starts up. –  Jay Cummins Nov 15 '10 at 12:58
    
That makes sense, hopefully he'll update it soon. –  Seth P. Nov 15 '10 at 14:29

I think I have used the export xml workspace document and chosen the schema only option. But it has been a few versions ago and I can't really remember how happy I was with that. It kinda seems like I got a myname and myname_1 version of some other gdb objects I didn't really want or need

share|improve this answer
1  
It works, but you get all domains plus empty feature datasets. –  Jay Cummins Nov 10 '10 at 16:38

For coded value domains, I'll do a Domain To Table from the source geodatabase and then do a Table To Domain into the new geodatabase.

I don't know of a way to this for the range domains. You can do a Domain To Table, but the Table To Domain always comes in as a coded value domain.

share|improve this answer
2  
I just used the Domain to Table and Table to Domain tools this morning and they worked great. –  Timothy Michael Mar 7 '12 at 14:49

This method is more hacky and only practical for 1 or a few domains.

  1. In the original geodatabase, create a dummy featureclass with a dummy field that matches the field data type of the domain that you wish to copy.

  2. Copy/Paste the dummy featureclass into the new geodatabase and don't delete it until you've assigned the domain to a field in another featureclass.

share|improve this answer

I wrote a quick command line arcobjects exe based on some vba code that I found last week. It's not complicated code.

Exe is here.
AVI movie here.

Fine print: The exe is compiled to 10.0 / ArcEditor license (the license is part is hard-coded for now).

alt text

share|improve this answer
    
I tried this out but I get exception errors, CopyDomain.exe canvec_blank.gdb target.gdb * Exception from HRESULT: 0x80040228 Exception from HRESULT: 0x80040228. Any ideas? –  matt wilkie May 31 '11 at 21:41
    
Don't know for sure, but are you an ArcEditor license? That was a quick&dirty tool, so it's probably not the most elegant tool. Do you have Visual Studio? The source is here: code.google.com/p/umbriel/source/browse/… –  Jay Cummins Jun 1 '11 at 2:01

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.