Page 1 of 1

Posted: 14 Jul 2017, 15:46
by sm_jamieson
There are several array modules that can select some items from the array according to some size limit. If the selection size is greater than the number of elements in the array, the array is increased in size and padded with zeros.

Can we have some way to stop the padding ? Often we want to limit the size of an array but never increase it. A common way to do this is to use a very high value for the "don't limit" condition, in which case we don't want the large value to cause an expansion.

A switch to indicate "don't expand" on the array handling modules would be useful.

There are patching and scripting workarounds, but they should not be required for such a simple logical operation.

A "Array Limit Size" module to complement "Array Set Size" module would also be useful - just to have that would help things a lot.

Thanks,
Simon.

Posted: 20 Sep 2017, 10:50
by senso
There are several array modules that can select some items from the array according to some size limit. If the selection size is greater than the number of elements in the array, the array is increased in size and padded with zeros.
Several? Not sure I only see Array Extract?
I'll implement a 'no padding' option in the Array Extract module.
A "Array Limit Size" module to complement "Array Set Size" module would also be useful - just to have that would help things a lot.
ok, I'll implement it