Skip to main content
Solved

Running different data streams through one transformer, preserving schema and then splitting back into original streams

  • December 8, 2023
  • 5 replies
  • 92 views

sam_appleton
Contributor
Forum|alt.badge.img+7

Hi All,

 

I've had something that I've been wondering about for a while.

In this example, I'm reading 11 SQL tables in using a feature reader and all of them contain a WKB column. I need to run these through a geometry replacer to assign their geometry.

 

image 

I tried running them all through a single geometry replacer, and using an attribute filter to return them into their own streams, but running them all through one transformer ruins the schema.

 

Is there anyway to return the original schema? Or do I need to create 11 different geometry replacers and keep each stream 'seperate'?

 

I'm aware that I can define the output attribute definition for each layer but I wanted to know if there was a less 'manual way.

 

Many thanks,

 

Sam

Best answer by dustin

What is your output writer format, and how is it configured? At the top of the FeatureReader, you have the schema outputs from each table. If you use a dynamic writer, the schema outputs can be used to define the schema in the writer. More detailed info can be found here: https://docs.safe.com/fme/html/FME-Form-Documentation/FME-Form/Workbench/Deriving-Destination-Schema-from-Schema-Feature.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

dustin
Influencer
Forum|alt.badge.img+31
  • Influencer
  • Best Answer
  • December 8, 2023

What is your output writer format, and how is it configured? At the top of the FeatureReader, you have the schema outputs from each table. If you use a dynamic writer, the schema outputs can be used to define the schema in the writer. More detailed info can be found here: https://docs.safe.com/fme/html/FME-Form-Documentation/FME-Form/Workbench/Deriving-Destination-Schema-from-Schema-Feature.htm


sam_appleton
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • December 8, 2023

What is your output writer format, and how is it configured? At the top of the FeatureReader, you have the schema outputs from each table. If you use a dynamic writer, the schema outputs can be used to define the schema in the writer. More detailed info can be found here: https://docs.safe.com/fme/html/FME-Form-Documentation/FME-Form/Workbench/Deriving-Destination-Schema-from-Schema-Feature.htm

I'm writing it to an SDE but usually do similar for File geodatabases. Thank you, I think the link you posted is exactly what i'll need!

 

do I need to connect the schema port from the reader, into the writer? Or is the schema info transmitted through the data ports too?


dustin
Influencer
Forum|alt.badge.img+31
  • Influencer
  • December 8, 2023

The schema features will need to be fed into the writer, and they will also need to arrive at the writer before the features. You can usually do this with a Sorter right before your writer.


sam_appleton
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • December 8, 2023

The schema features will need to be fed into the writer, and they will also need to arrive at the writer before the features. You can usually do this with a Sorter right before your writer.

Thank you for your help, i'll need to and have a play with this and wrap my head around it :)


dustin
Influencer
Forum|alt.badge.img+31
  • Influencer
  • December 8, 2023

Thank you for your help, i'll need to and have a play with this and wrap my head around it :)

FME has lots of articles on dynamic writing if you search the technical forums for 'dynamic writing'.