I'm trying to create a self service FME Server workspace app, that will accept, as an input, either a shapefile or an FGDB feature class. Is this possible?
Solved
I'm trying to create a self service FME Server workspace app, that will accept, as an input, either a shapefile or an FGDB feature class. Is this possible?
I want to be able to present the user with a single input option that will accept either a shapefile or an FGDB feature class. It doesn't seem possible to me because:
the generic reader doesn't seem to allow you select an FGDB
I can't have a shapefile reader and an FGDB reader in my workspace, but only use one
Am I really going to have to create 2 workspace apps, one that processes shapefiles and one that processes FGDB feature classes?
FME Desktop 2021.2 and FME Server 2021.2.
Best answer by david_r
oihdosj wrote:
Thanks @david_r. So, if I understand you correctly, I need a (required) published parameter to identify whether the user is going to upload a shapefile or an FGDB, then 2 (optional) published parameters for the shapefile/FGDB file paths?
That could be one way of doing it. Or you could support a single zip file, then check the contents of the zip file in FME (you can point a FeatureReader using the "Directory and File Pathnames" reader to the zip file) and redirect to the appropriate reader, depending on what you find inside.
You don't have to use the generic reader, simply use two different FeatureReaders, for example:
That said, I'm fairly sure the generic reader is able to read a FGDB.
Thanks @david_r. So, if I understand you correctly, I need a (required) published parameter to identify whether the user is going to upload a shapefile or an FGDB, then 2 (optional) published parameters for the shapefile/FGDB file paths?
Thanks @david_r. So, if I understand you correctly, I need a (required) published parameter to identify whether the user is going to upload a shapefile or an FGDB, then 2 (optional) published parameters for the shapefile/FGDB file paths?
That could be one way of doing it. Or you could support a single zip file, then check the contents of the zip file in FME (you can point a FeatureReader using the "Directory and File Pathnames" reader to the zip file) and redirect to the appropriate reader, depending on what you find inside.
Thanks @david_r. So, if I understand you correctly, I need a (required) published parameter to identify whether the user is going to upload a shapefile or an FGDB, then 2 (optional) published parameters for the shapefile/FGDB file paths?
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.