cancel
Showing results for 
Search instead for 
Did you mean: 

How to create multi rows dynamically?

sdeng
New Contributor II

we have a snap to get a count from the previous snap, then once we got the count(there’s only one output), for example, if we got 10, we will need to create 10 outputs in the next mapper, how can we do that? Is there any formula we can use?

1 ACCEPTED SOLUTION

Aleksandar_A
Contributor III

Hello @sdeng,

You can use sl.range() function, to generate an array of elements and then you can map them and split them according to your requirements.

Please refer to the sample pipeline attached below:

–sl-comm-generate-documents_2023_05_18.slp (4.7 KB)

Let me know if this helps you. 🙂

BR,
Aleksandar.

View solution in original post

2 REPLIES 2

Aleksandar_A
Contributor III

Hello @sdeng,

You can use sl.range() function, to generate an array of elements and then you can map them and split them according to your requirements.

Please refer to the sample pipeline attached below:

–sl-comm-generate-documents_2023_05_18.slp (4.7 KB)

Let me know if this helps you. 🙂

BR,
Aleksandar.

sdeng
New Contributor II

Thanks, it’s working!! 😀