This command extracts a string value from the text buffer.
It allows you to specify which characters will be used to break the text buffer into columns and which characters are used to delimit text strings.
Syntax
COLUMN "column_separators", "text_qualifiers", column_number
"Column_separators" should specify the characters that should be used to break the text buffer into columns.
"Text_qualifiers" should specify the characters that are used to delimit text strings. These characters will be removed from the string value that is returned by this command. If no text qualifiers are present in the buffer, you may specify an empty string ("") for this parameter.
Column_number must be an integer that specifies a column in the text buffer from which to extract data.
Return value
This command returns a string.
Notes
Characters that are commonly used as column_separators include:
tab (ASCII code 9)
space (ASCII code 32)
comma (ASCII code 44)
Characters that are commonly used as text_qualifiers include:
single quotation mark (ASCII code 39)
double quotation mark (ASCII code 34)
If you need to reference the ASCII code for a character instead of specifying the character itself, use the CHR command.
If you need to convert the result string to a numeric value, use the VAL command.
Examples
COLUMN ":" , "" , 4
This formula specifies that the column_separators include only the colon character (:), and it specifies no text_qualifiers.
If the text buffer contains the string 01: 123.32: 1234: M22 , this formula returns the string "M22".
COLUMN "," , "<>" , 2
This formula specifies that the column_separators include only the comma (,), and it specifies that the text_qualifiers include both the left and right angle bracket characters (<>).
If the text buffer contains the string <5.5>, <2.2> , this formula returns the string "2.2".
COLUMN (CHR 44) , (CHR 39) , 2
This formula specifies that the column_separators include only the comma (CHR 44), and it specifies that the text_qualifiers include only the single quotation mark character (CHR 39).
If the text buffer contains the string '5.5', '2.2' , this formula returns the string "2.2".
VAL ( COLUMN (CHR 44) , (CHR 39) , 2 )
This formula specifies that the column_separators include only the comma (CHR 44), and it specifies that the text_qualifiers include only the single quotation mark character (CHR 39). It also uses the VAL command to return the numeric value of the string returned by the COLUMN command.
If the text buffer contains the string '5.5', '2.2' , this formula returns the number 2.2.