Subscribe Bookmark RSS Feed

Using GetRowsWhere

brianq_

Community Trekker

Joined:

Jun 23, 2011

I'm trying to use the "Get Rows Where ()" function, but I am having difficulty getting the script to work without hard coding the column names.

For example the following 2 lines of code work:
my_list = dt<my_list = dt<
However I do not want to hardcode the column name and I want to use code similar to the following:
target_col = Column(dt,"DataSetId");
my_list = dt<
I've tried various combinations of things including (based mostly on complete guesses), but haven't been able to come up with a working solution. Any help with this would be appreciated. Thanks!
3 REPLIES
Try this:

In the line

my_list = dt<
replace target_col with target_col[]
brianq_

Community Trekker

Joined:

Jun 23, 2011

Thanks a ton! Works like a charm! =)
Jeff_Perkinson

Community Manager

Joined:

Jun 23, 2011

The As Column() function may help to make it a little clearer what's going on.

my_list = dt<
Jeff
-Jeff