Skip to main content
Solved

Copy content of the table


Forum|alt.badge.img

Hello,

How can I copy content of the table?

 

 

For instance, my table looks like this:

Out of above table I would like to create below table:

Best answer by redgeographics

You can use a Cloner to make 1 copy of each record. If you have the No. field set to autonumber the writer will sort it out, otherwise you can use a Counter to create a new, unique, number for each record.

View original
Did this help you find an answer to your question?

2 replies

redgeographics
Celebrity
Forum|alt.badge.img+49
  • Celebrity
  • Best Answer
  • May 1, 2018

You can use a Cloner to make 1 copy of each record. If you have the No. field set to autonumber the writer will sort it out, otherwise you can use a Counter to create a new, unique, number for each record.


takashi
Influencer
  • May 1, 2018

I like the Cloner use, but there is more than one way. e.g.

  • Divide the data flow into two streams, put a FeatureHolder on one of them, then connect them to a single Counter to update "No." with 1-based sequential number.
  • Create two features with a Creator, connect it to a FeatureReader to read the table twice, then connect a Counter to update "No.".
  • Read the table twice with two readers, send all the feature into a single Counter.
  • InlineQuerier (union two tables with a SQL statement) + Counter, etc...

And, if the source format was CSV and you are using FME 2017+, surprisingly, this workflow does that, since the modern CSV2 reader implements the "feature table" technology.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings