Skip to main content

Hello!

 

For an FME Batch process I am working with the Workspace runner. In the two main FME workbenches a conversion from GeoJSON EPSG 4326 to Shapefile EPSG 31256 is made. In the second main workbench there is a conversion in the opposite direction. My question now is the following:

 

In the Workspace that actually runs the two "main" workspaces I am using the Directory and File Pathname Reader. In this reader I defined the folder, where the Input GeoJSON and Shapefiles are stored. (attached you van find a Picture of the Workspace.) This path I connected to the two WorkspaceRunners (1 for GeoJSON and one for the Shapefile Converter. For source (GeoJSON/Shape) I used path_windows).

 

My Problem is that for the process of Shape -> GeoJSON I always get an error '...se_shape_2.shx' lacks the required extension `shp', altough the shx, prj and dbf file belong to the shapefile.

 

Is there ANY way how FME recognizes that these files also belong to the shapefile?

 

 

Thanks a lot.

Can you use a testfilter after the PATH reader to filter out .shp files in one direction, .json in another and then do nothing with the other files in the folder, e.g. shx


Can you use a testfilter after the PATH reader to filter out .shp files in one direction, .json in another and then do nothing with the other files in the folder, e.g. shx

Hi @egomm, thanks a lot for the tip! Unfortunately all four(shx/shp/prj/dbf) are needed do to the feature attributes and projection information. Do you maybe have an idea how FME could recognize all of them as the one "shapefile"?


Hi @egomm, thanks a lot for the tip! Unfortunately all four(shx/shp/prj/dbf) are needed do to the feature attributes and projection information. Do you maybe have an idea how FME could recognize all of them as the one "shapefile"?

I'm not sure i follow. You should only have to read the .shp file. The other files need to be present alongside the shp file in the folder it's in but you don't need to read them separately.


As egomm mentioned, to read the attribute, and projection info from the associated files, FME only need to read the file with .shp extension. So, in your Directory and File Pathnames reader, you can add a Path Filter to only read .shp. Hope this helps.

 


Reply