Hello All,
Do we have any logic exists for grouping the array of data's into single array item and so on? Here is a quick example
Suppose my CDT has total 10 items. Now I want to reconfigure this item in a way that a second variable has 5 items grouped together as an array of 1 and another 5 items will be grouped as an array of 2. Any suggestion here would be appreciated
Discussion posts and replies are publicly visible
I am not sure how exactly you want it to group, I have placed a sample code below. take a look into it and let me know if it helps
with(
local!data:{1,2,3,4,5,6},/*Data list*/
local!columnCount:3,/*Number of columns*/
local!column: a!forEach(
enumerate(local!columnCount),
index(local!data, where( apply(
mod(_,local!columnCount),enumerate(count(local!data)))=fv!item),{})
) ,
local!column
)