clearing of a select filter

  • Thread starter Thread starter Bernie Yaeger
  • Start date Start date
B

Bernie Yaeger

If my table contains 10 row, with 3 matching the first select, will all 10
again be evaluated on the next select? Here's what I mean:
irows = dshistd.Tables(0).Select("bipad = '1234'")

If, later, I do this

irows = dshistd.Tables(0).Select("bipad = '5678'")

will I get those that match out of the original 10 or, if I do nothing to
clear the first select, will dshistd.tables(0) only have rows with bipad =
'1234' to offer? If so, what it the correct method of clearing the select?

Thanks for any help.

Bernie Yaeger
 
Bernie said:
If my table contains 10 row, with 3 matching the first select, will
all 10 again be evaluated on the next select?

Yes. The Select method returns matching DataRows, it does nothing to
alter the content of the DataTable.

BTW, you might consider using the RowFilter property of the DataTable's
DefaultView member. DefaultView is a DataView and these are very handy
for sorting and filtering.

--
There are 10 kinds of people. Those who understand binary and those who
don't.

http://code.acadx.com
(Pull the pin to reply)
 
Hi Frank,

Tx for your help.

Bernie
Frank Oquendo said:
Yes. The Select method returns matching DataRows, it does nothing to
alter the content of the DataTable.

BTW, you might consider using the RowFilter property of the DataTable's
DefaultView member. DefaultView is a DataView and these are very handy
for sorting and filtering.

--
There are 10 kinds of people. Those who understand binary and those who
don't.

http://code.acadx.com
(Pull the pin to reply)
 
Back
Top