Hello,
I have one feature reader that reads one table City, then I have another reader that reads table Person and then for each feature from City and for each feature from Person that are merged I'm performing job submitter operation with parameters CityId, PersonId
Â
I would like to change it a bit:
What I would like to achieve is to take all objects from City and then take all objects from Person but then group results from Person to merge every n records into one.
Â
As example:
Â
Lets say I have 2 records in City table:
Â
New YorkÂ
ChicagoÂ
And I have 4 records in Person table:
Person1Person2Person3Person4Â
In o regular flow I would have JobSubmitter executed 8 times for:
Â
Â
Â
Â
Â
CITY IDPERSON IDCITY IDPERSON IDNew YorkÂ
Person1Â
ChicagoÂ
Person1
New YorkÂ
Person2Â
ChicagoPerson2Â
New YorkÂ
Person3Â
ChicagoÂ
Person3Â
New YorkÂ
Person4Â
ChicagoÂ
Person4Â
Â
What I would like to do is to group every n row from Person table and merge PersonIds into one attribute and modifie it a bit (by adding '' and ,) so for example for n = 2 job submitter would be executed only 4 times and it would look like:
Â
Â
Â
CITY IDPERSONIDNew York'Person1','Person2'New York'Person3','Person4'Chicago'Person1','Person2'Chicago'Person3','Person4'Â
For n = 3 it will be also executed 2 times but for n = 4 only 2 times.
Â
What is the best way to do that?