Parameters: (String comma_seperated_numeric_values);
Returns: Decimal;
Extracts all numeric values from the comma seperated list and outputs the largest of these.
- If the list is entry, NULL is returned
- If the list contains non-numeric values, these are ignored and a warning is added to the report for ths record.
- The values in the csv list can optionally be delimited by double quotes.
- If the CSV list has an incorrect format (for example an un-closed double quote) an error occurs and this will be handled depending on the error action.
- Negative values, integers and decimals are supported
- A maximum of 1000 values in the list is supported. Any additional values are ignored
Examples:
1. MAX_IN_LIST('3,6,9,13,1,8') Result: 13.0
2. MAX_IN_LIST('"3","6","7","18","1","19"') Result: 19.0
3. MAX_IN_LIST('"1,2,3,"Hello",9,"World"') Result: 9.0 {warning added for the non-numeric values}
4. MAX_IN_LIST('') Result: NULL
5. MAX_IN_LIST('"1,2,3') Result: ERROR {unclosed double quote delimiter}
Comments
0 comments
Please sign in to leave a comment.