dynamic record filtering

  • Thread starter Thread starter Craig Buchanan
  • Start date Start date
C

Craig Buchanan

I have a class that returns email address. I would like to provide a way to
filter the address based on a number of criteria. Originally, I thought
about doing this in a stored procedure, but based on which fields are being
used in the filter, this is problematic.

Is there a way to apply a filter to a SQLDataReader? Is there another
option?

Thanks,

Craig Buchanan
 
Hi Craig,

Craig Buchanan said:
I have a class that returns email address. I would like to provide a way to
filter the address based on a number of criteria. Originally, I thought
about doing this in a stored procedure, but based on which fields are being
used in the filter, this is problematic.

Is there a way to apply a filter to a SQLDataReader? Is there another
option?

You should apply filter to sql command directly (either using parametrised
statament - preffered or by concatenating string).
 
Back
Top