简体   繁体   中英

Use saved column names in a list as a filter iron python

I am new to iron python. This is my first code. I need to create a list filter that contains all the column names of a table. If I select a particular column name, the name of the column has to be stored in a document property. Using that document property I will create some calculated columns.

Can anyone please guide me how to achieve this requirement?

I am able to do some reading and save all the columns in a list but I don't know how to proceed further.

from Spotfire.Dxp.Data import *

colNames = []
table = Document.Data.Tables['TableName']
for column in table.Columns:
    colNames.append(column.Name)
print(colNames)

It is possible in spotfire analyst itself. Instead of using iron python I used "insert input field" and created a column property and added the columns for filtering.

any other suggestions are welcome for me to learn.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM