Skip to main content

Hi,

It seems I've uncovered an error in the automated (when run) export of FMW workspace to FME mapping file.

My setup includes a custom transformer, which contains a SpatialRelator. I just parameterized the SpatialRelator's "Input Ordered" and "Group By" entries (by choosing the automated creation of new published parameters). The "Group By" ends up as an optional "Attribute List (space delimited)".

However, the workspace now fails with:

f_51(TransformFact): Definition of transformer 'SpatialCrossJoiner_SpatialRelator' is invalid. 'PROCESS_GROUP_BY' statement doesn't have 2 tokens

I then exporting it to an FME, and searched for "PROCESS_GROUP_BY", and found it.

FACTORY_DEF * TransformFact:9:SpatialRelator                           \
   FACTORY_NAME "$(SpatialCrossJoiner_WORKSPACE_NAME)_SpatialRelator"  \
   FACTORY_META_PARAMS                                                 \
   TRANSFORMER_NAME:"$(SpatialCrossJoiner_WORKSPACE_NAME)_SpatialRelator" \
   TRANSFORMER_PARAMS:XFORMER_NAME,$(SpatialCrossJoiner_WORKSPACE_NAME)_SpatialRelator,TRANSFORMER_GROUP,,GROUP_BY,$($(SpatialCrossJoiner_WORKSPACE_NAME)_GROUP_BY$encode),TESTS_GROUP,,AGGREGATE_HANDLING,Yes,PREDICATES,$($(SpatialCrossJoiner_WORKSPACE_NAME)_RELATIONS$encode),DIFFATTRS,,CURVE_BOUNDARY_RULE_PARAM,Default<space>Rule,OUTPUT_GROUP,,SUCCESS_ATTR,_related_candidates,CALC_CARD,No,ATTR_ACCUM_GROUP,YES,MERGE_ATTR_GROUP,YES,ATTR_ACCUM_MODE,Merge<space>Supplier,ATTR_CONFLICT_RES,Use<space>Requestor,ATTR_PREFIX,<lt>Unused<gt>,GENERATE_LIST_GROUP,YES,LIST_NAME,_relationships,LIST_ATTRS_TO_INCLUDE_MODE,All<space>Attributes,LIST_ATTRS_TO_INCLUDE,<lt>Unused<gt> \
   PROCESS_GROUP_BY $($(SpatialCrossJoiner_WORKSPACE_NAME)_GROUP_BY)   \
   MULTI_PROCESS "NO_PARALLELISM"                                      \
   GROUPS_ARE_ORDERED $($(SpatialCrossJoiner_WORKSPACE_NAME)_GROUPS_ORDERED) \
INPUT Requestor FEATURE_TYPE "$(SpatialCrossJoiner_WORKSPACE_NAME)_Save_feature_type_OUTPUT" \
INPUT Supplier FEATURE_TYPE "$(SpatialCrossJoiner_WORKSPACE_NAME)_Supplier" \
   OUTPUT Output FEATURE_TYPE "$(SpatialCrossJoiner_WORKSPACE_NAME)_SpatialRelator_Output"

It seems that the line with PROCESS_GROUP_BY needs to have its argument in quotes.

I put quotes around the argument, and ran the mapping file instead of the workspace, and it worked !

PROCESS_GROUP_BY "$($(SpatialCrossJoiner_WORKSPACE_NAME)_GROUP_BY)"

Unfortunately I'll have to do a manual save+edit to run my workspace now :-(

Please fix. I'm using 2017.1 x64.

Hi @lifalin2016,

If you would like to provide me with a copy of your workspace, I would be happy to create a problem report for our development team, in order to get this issue fixed for you. If you don't want to share the workspace publicly, please email it to support@safe.com, attn. Dave.


If the Order By parameter in the Spatial Relator is published in a custom transformer, and no attribute is chosen in the Group By parameter, the transformer will fail, both in Workbench and on the command line.

I have created a problem report for our development team (PR80356), and will notify you as soon as it is fixed.As a workaround for now, please add a common attribute to all the input feature and set its value to 1. This will give you an attribute to Group By that is the same as having no Group By, which should avoid the transformer failure.

Reply