Hello FME community,
I have loaded a text file as CSV into the workflow so that a table is created.
This then looks like this:I need a process that can work independently of the number of attributes but according to a pattern.
Therefore I have converted these attributes into a list.
Here is an excerpt from it: (fme_basename: 102)
_list{0}.col2 892
_list{0}.col3 1448
_list{0}.col4 48
_list{0}.col5 70
_list{0}.col6 874
_list{0}.col7 1628
_list{0}.col8 50
_list{0}.col9 78
The pattern looks like this:
col2 and col6 belong in one attribute (x)
col3 and col7 belong in one attribute (y)
col4 and col8 belong in one attribute (dx)
col5 and col9 belong in one attribute (dy)
So every 4th element belongs to the same attribute.
I would like to change the list so that the index can be set according to the pattern.
This would then have to look like this:
_list{0}.col2 892
_list{1}.col3 1448
_list{2}.col4 48
_list{3}.col5 70
_list{0}.col6 874
_list{1}.col7 1628
_list{2}.col8 50
_list{3}.col9 78
Then I would have the possibility, based on the index, to write the elements into the respective attributes.
Do you guys have any ideas on how to make this happen?
I am not proficient in the programming language. Otherwise this would probably be a piece of cake.
Best regards