- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Get Rows() not working
I have
row_nums = data << Get Rows Where( num(data:"Donor") == i & data:"A or B" == "A");
d_A_rows = data << Get Rows(row_nums);
Write(d_A_rows);
but it writes the row numbers still instead of the actual row content. Am I missing something?
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Get Rows() not working
Hi,
You can do this:
row_nums = data << Get Rows Where( Num( data:"Donor" ) == i & data:"A or B" == "A" );
Write( data[row_nums, 0] );
Once you have the row numbers you need in row_nums, you can index the table (which I presumed is named data) directly using the syntax table[row,col]. In your case, row_nums are the rows you want, and 0 means to get all columns.
Cheers,
Brady
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Get Rows() not working
Hi,
You can do this:
row_nums = data << Get Rows Where( Num( data:"Donor" ) == i & data:"A or B" == "A" );
Write( data[row_nums, 0] );
Once you have the row numbers you need in row_nums, you can index the table (which I presumed is named data) directly using the syntax table[row,col]. In your case, row_nums are the rows you want, and 0 means to get all columns.
Cheers,
Brady
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Get Rows() not working
Thank you. That works perfectly, and is very incisive in educating me about coordinate-indexing tables as well.