Question

FEM 2012 Sp2 - Custom transformers, Loops, ExpressionEvaluator


Badge

Hello,

Is there an issue with having an expressionEvaluator inside a Custom Transformer that has a Transformer Loop?

I want to call a workbench passing a date of a possible file but I only want it to do so 32 times.

I am using a creator to initialise a counter variable, (I am using Creator instead of having to read in features), then I set an attribute with todays date via DateFormatter, then inside the loop, ExpressionEvaluator to increment the counter variable, then a tester to make sure I haven't gone through the loop more than 32 times, then some processing on the date, and then the Transformer Loop to go back to the start where ExpressionEvaluator than is supposed to increment the counter variable again.

When I the Inspection tool, I see that the counter variable and all the other variables are wiped.

Is there a bug in 2012 SP2?


7 replies

Userlevel 2
Badge +17
Hi,

 

 

I suppose the usage of Creator caused the unexpected result. But the exact reason cannot be specified unless the structure of your custom transformer will be more clear. Could you show us a screen shot of your custom transformer?

 

 

Takashi
Badge
Hello takashi,

 

 

Can I send the workbench via drop box, if that helps?

 

 

 

Userlevel 2
Badge +17
Hi,

 

 

Yes. Paste the link here, then we all can see that.
Userlevel 4
Badge +25
I don't see a reason why it should be a problem, so we'll have to wait to see the workspace.
Badge
Might have to close this question. I am using a Tranformer 'DateSetter' I downloaded from the FME store but I didn;t read the Requirements where it stated FME 2013 SP1+.

 

When I run WB 1 and loo at the returned date, the date is in the future by some amount of days i.e. 04/03/2014 , 02/04/2014 , 03/02/2014

 

 

Mights just not work in FME 2012 SP 4.
Userlevel 2
Badge +17
Hi,

 

 

I suppose it's a problem concerning to 'Source Format' parameter of DateFormatter. I would recommend you to look over whether the format of input date string is always same as 'Source Format', at every time in the loop.

 

Takashi
Badge
Resolved, apologies for not getting back sooner,

 

the issue was I was converting the date to d/m/yyyy and the DateFormatter transformer doesn't like that. Helps to carefully read the help docco :)

 

The source string must be in a date and/or time format supported by the transformer.

 

Reply