CSV_BIGDEC( csv_data, header => 'column header' );
CSV_BIGDEC( csv_data, ID => relative-column ID );
The CSV Function parses the csv_data passed to it and returns the
data for the column identified by the 2nd parameter. The 2nd
parameter may be the relative column number or the column heading.
This Function is primarily used with the iQuery CSV() UDTF to parse the CSV content.
This UDF returns the column content as a Packed Decimal with
63-digits in length and 15-decimal positions. The value can be
cast to the length and decimal positions desired, but can also
typically be Fetched into a host variable that is the right size
without the need to cast it. For example if the accumulated
30-years sales figures are more than 31 digits, then casting the
column might look like the following:
CAST( iQuery.csv_bigdec(data, 'Lifetimesales') as dec(37,2) )
Expected value: DATA
When the HEADER version of this UDF is used, the column heading
(enclosed in single quotes) is specified to identify the column
whose data is to be returned.
When the Relative Column ID version of this UDF is used, ID
identifies the relative column number whose data is returned.