I need to calculate the average time spent per service request by counting the number of logged call numbers stored in a column as a comma-delimited string.
[NAME] [CALL REF NR] [NR OF HOURS]
Joe Soap “a12, a23, d45, x22” 10
I need a way to calculate that Joe Soap has 4 reference numbers - i.e. so that 10 hours / 4 calls = 2.5hr per call
After using Cell Splitter (with the list object setting) it splits the strings using a “,” delimiter. I later use this for other operations. I cannot find a way to extract the list or array size from the node in a standard way. Does any one have a perspective on how I can obtain the list size - I would then run a math function or similar to calculate the average. I’m trying to avoid custom code if possible.
Side question and note: So .split(",").length works perfectly, but it’s not listed in the function specficiation in the configuration dialog - is this maybe because the function list is still to be updated?
That’s due to the fact that the the Column Expressions Node provides predefined functions that can be easily used by everybody, while ‘.split(",")’ and ‘.length’ are called on so called objects (String and array).
We are currently working on collection support, i.e. using collections and retrieving collections in expressions.
And thus introducing more functions, such as split and length, that can be easily used as the already contained functions.