Skip to main content
Solved

How do I loop in this situation?

  • July 29, 2024
  • 5 replies
  • 104 views

mr_fme
Enthusiast
Forum|alt.badge.img+9

Hi,

I have a process that begins by going through the AttributeCreator2 transformer, but after some transformers, there is a validation. If the result is true, the features will arrive at the DateTimeConverter as shown in the image below...
 

 

I would like the process to restart at the SentinelDownloader transformer after the DateTimeConverter returns, and to consider the features with the AttributeCreator transformer only at the start of the entire process. I guess the process should work like a loop.

Thanks

Best answer by liamfez

I am not exactly sure what your end goal may be, “looping” may not be the best solution. But one solution may be to add all of the relevant transformers to a new custom transformer. You could then add that custom transformer to the canvas again after the DateTimeConverter.

You may also want to look into this documentation for looping with custom transformers to see if that is what you are looking for. https://docs.safe.com/fme/html/FME-Form-Documentation/FME-Form/Workbench/transformers_custom_looping.htm

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

5 replies

liamfez
Influencer
Forum|alt.badge.img+44
  • Influencer
  • July 29, 2024

Are you saying you would like the features coming out of the DateTimeConverter to enter the SentinelDownloader and be processed by all the following transformers?

Or are you saying you simply want the whole process to run again once the first run is complete and outputs data?


mr_fme
Enthusiast
Forum|alt.badge.img+9
  • Author
  • Enthusiast
  • July 29, 2024

Yes!  I would like the features coming out of the DateTimeConverter to enter the SentinelDownloader and be processed by all the following transformers, but the process begins in Attribute Creator, the second, third...pass will be DateTimeConverter like a loop process…

 

 


jkr_wrk
Influencer
Forum|alt.badge.img+35
  • July 29, 2024

It's better to explain what is happening in your workbench. Because most of the time looping is not the solution in FME.

If it is really the solution you have to create a CustomTransformer and set up a looping flow.

But maybe take a look at https://www.safe.com/webinars/to-loop-or-not-to-loop-overcoming-roadblocks-with-fme/


liamfez
Influencer
Forum|alt.badge.img+44
  • Influencer
  • Best Answer
  • July 29, 2024

I am not exactly sure what your end goal may be, “looping” may not be the best solution. But one solution may be to add all of the relevant transformers to a new custom transformer. You could then add that custom transformer to the canvas again after the DateTimeConverter.

You may also want to look into this documentation for looping with custom transformers to see if that is what you are looking for. https://docs.safe.com/fme/html/FME-Form-Documentation/FME-Form/Workbench/transformers_custom_looping.htm


mr_fme
Enthusiast
Forum|alt.badge.img+9
  • Author
  • Enthusiast
  • July 29, 2024

@liamfez I guess the custom transformer a best way.

 

Thanks