You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently I've participated in threads where the user are using fields which could contain just one item, and as such is a "number" or "string", or it could have multiple items and the field is therefore and "array". We've then proceeded to do stuff like the following:
choice( typeof(someField) = "array", someField, list(someField) ) as someFieldList
This transform it so one can reliably use array function independent on it being a single or multiple value(s). So my question is would it be beneficial to have an asArray() function to do just this operation, so that the end user can reliably treat the field as an array later on (instead of loosing values/notes which are of the other variant (aka multiple values when expecting single value, or vice versa)?
So what do you say, would it be useful to have an asArray() function as depicted above?
(I can make it for sure, but I just wanted some input if this would be as useful as I think it would be)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Recently I've participated in threads where the user are using fields which could contain just one item, and as such is a "number" or "string", or it could have multiple items and the field is therefore and "array". We've then proceeded to do stuff like the following:
This transform it so one can reliably use array function independent on it being a single or multiple value(s). So my question is would it be beneficial to have an
asArray()
function to do just this operation, so that the end user can reliably treat the field as an array later on (instead of loosing values/notes which are of the other variant (aka multiple values when expecting single value, or vice versa)?Some threads where this logic has been applied:
country
partSo what do you say, would it be useful to have an
asArray()
function as depicted above?(I can make it for sure, but I just wanted some input if this would be as useful as I think it would be)
Beta Was this translation helpful? Give feedback.
All reactions