The attached workspace demonstrates the problems I'm having with @ReplaceRegEx and user parameters. What I'm trying to do is create an output folder name QC within the folder where the input dataset is located.
I've created a private user parameter named OutputFolder of type Folder (output) and set it's default value to:
@ReplaceRegEx($(SourceDataset_MAPINFO),"^(.+)\\.+$","\1\QC")
The intent of the workspace is to simply read the input dataset, create the output folder QC within input dataset folder, and finally write the input dataset to the output folder.
When I run the workspace I get the following error messages:
Could not create output folder `@ReplaceRegEx(C:\temp\InputGeometries.tab,^(.+)\.+$,\1\QC)' for use by MAPINFO writer
Could not create output folder `@ReplaceRegEx(C:\temp\InputGeometries.tab,^(.+)\.+$,\1\QC)' for use by MAPINFO writer
Destination Feature Type Routing Correlator(RoutingFactory): Could not create output folder `@ReplaceRegEx(C:\temp\InputGeometries.tab,^(.+)\.+$,\1\QC)' for use by MAPINFO writer
It's as though FME is literally taking the @ReplaceRegEx expression as the output folder name, and not the result from evaluating the regex.
Also, in the error message, notice how the quotation marks around the pattern and replacement string literals are missing? Not sure what is happening here.
Any help is greatly appreciated.
Thanks,
Brian