Answers for "Extracting coordinate system from FILE GDB Feature Dataset when feature class is empty." https://knowledge.亚搏在线safe.com/questions/55656/extracting-coordinate-system-from-file-gdb-feature.html The latest answers for the question "Extracting coordinate system from FILE GDB Feature Dataset when feature class is empty." Answer by daveatsafe https://knowledge.safe.com/answers/55684/view.html

Hi@dfresh,

If you use the Esri Geodatabase (ArcObjects) reader, you have the option to set the Feature Read Mode to Metadata.This will allow the reader to return a metadata feature for each feature class.

The metadata feature geometry will be the bounds of the feature class, in the feature class coordinate system, so you can use a CoordinateSystemExtractor to get the coordinate system name in an attribute.

If you want the Esri WKT for this coordinate system, you can use the CoordinateSystemDescriptionConverter transformer to convert the attribute containing the FME coordinate system name to Esri WKT.

Fri, 13 Oct 2017 20:14:22 GMT daveatsafe
Answer by danilo_fme https://knowledge.safe.com/answers/55660/view.html

Hi@dfresh,

Did you try to use a PythonCaller and a scrpit to get the coordinatesystem:

import fme import fmeobjects def _sistema_coord(feature): csMgr = fmeobjects.FMECoordSysManager() # call coord system cs = feature.getCoordSys() #get the coord system of features if cs != None and cs != '': params = csMgr.getCoordSysParms(cs) if 'EPSG' in params: loc = params.index('EPSG') + 1 feature.setAttribute('EPSG',params[loc])

But i believe to need to have a feature beforr this transformer.

Thanks,

Danilo

Fri, 13 Oct 2017 16:07:04 GMT danilo_fme