Using Custom Columns
Learn how to quickly create custom columns based on your data.
About Custom Columns
Section titled “About Custom Columns”You can create entirely new columns without using SQL
by adding a column directly into the frame. Custom columns use Coco Expression syntax to construct entirely new columns based on existing columns and functions you provide.
An example may be to split a column by a delimiter and take the second value.
Creating a Custom Column
Section titled “Creating a Custom Column”Select a column, and right-click. Then select the “Insert” option. This will place a custom column before the column you selected.
Provide an Expression
Section titled “Provide an Expression”Custom columns only accept constant expressions. This means you cannot use keywords like SELECT
, JOIN
, etc.
You can use scalar keywords like CASE WHEN
, etc.
Aggregates are handled specially, where average(col)
will calculate the average for the entire column, without a grouping required.
Write your expression in the upper expression box. It’s similar to Excel, where you can reference other existing columns. However, cells are not supported…
Your results will be previewed in real time. The only caveat to this is when aggregate expressions are involved. In that case, you will have to apply your expression and create the column in order to see the results.
See More
Section titled “See More”For more information on the functions available in Coco Expressions, please see the Coco Expressions Reference