Jump to content

Select Column to send to data function from a document property


David Katz
Go to solution Solved by Gaia Paolini,

Recommended Posts

  • Solution

singleColumnExpression.jpg.21f343beeea993cd7599cc0212547209.jpgmultipleColumnsExpression.jpg.dbbb6f8b652e689affa5f1d8ec092406.jpgIf you only want to select a single column (say defined via document property ColumnToSelect)

then when you are specifying the parameters to your data table, choose Expression as Input handler

and type the following custom expression in the expression editor:

[iris].[${ColumnToSelect}]

in this example I am using a data table called iris, change the name to yours but make sure it is also selected as a data table

at the top of your expression (see TOP picture) otherwise Spotfire will complain that it does not find the table.

If you want to send multiple columns (defined via a multi-selection document property ColumnsToSelect)

then use the following expression: (see SECOND picture)

$map("[iris].[${ColumnsToSelect}]", ",")

which is actually typed for you automatically if you go and select the document property and right click on it 

on the Available properties for column list above the expression editor.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...