I would like to get a list of geodatabase feature tables from FME. Is it possible with Python? Or another transformer?
-
Do you specifically need to get this list from FME? I only ask since it looks like the data is coming from an Esri geodatabase. Would an ArcCatalog solution be acceptable? – RyanKDalton Jun 06 '11 at 22:03
-
ArcCatalog is not the final solution for the development. I use a workbench and i would like a list of GDB feature because i would like to export the feature table to an another file. – Jun 06 '11 at 22:12
-
1I find the solution with Python is here (http://gis.stackexchange.com/questions/9981/how-to-list-feature-classes-with-active-attribute-domains) – Jun 07 '11 at 02:23
-
1As long as you have the ESRI stuff installed; ArcPy is just a wrapper to the ArcGIS classes/Methods; if you are wanting to keep this entirely in the FME realm then Mark's answer is probably your best bet. – D.E.Wright Jun 07 '11 at 17:12
2 Answers
I would use a dynamic reader (ie one with just a single source feature type with the merge filter set). Then expose the fme_feature_type format attribute. This will give you the name of the table being read.
You can run the data through a DuplicateRemover too, removing duplicate values for fme_feature_type, in order to get a list of unique table names.
There is a Schema format that returns the schema of a dataset, but I think it works only with file-based data, and wouldn't work with a File Geodatabase (though it might with a Personal Geodatabase).
- 13,147
- 3
- 33
- 67
-
Ok, I saw that but didn't have the time to play with it. Thanks for the suggestion Mark! – D.E.Wright Jun 06 '11 at 23:33
-
-
1There shouldn't be any need to use Python. Just expose the source format attribute called fme_feature_type - that will tell you the name of the table where the feature is from. It doesn't need to be dynamic either - I just suggest that as a way for the workspace to operate on any source dataset. – Mark Ireland Jun 08 '11 at 16:31
Yes, you can list object in any ESRI connection; as long as you have the ArcGIS Server installed on that machine you can use the list object in ArcPy to return a array of feature classes.
You will just want to make sure that is you are dynamically checking a variety of Geodatabases that you have your parameter for your workspace set.
- 5,497
- 23
- 32
-
I use a geodatabase file and fme desktop.I have not ArcGis server on my desktop. – Jun 06 '11 at 22:50
-
Hmmm, ok; that is a different place. I am digging through my Workbench and for the life of me am not seeing a place to actually list what is in the Reader. – D.E.Wright Jun 06 '11 at 23:14