SQL Queries in ADO.NET datatables

  • Thread starter Thread starter Brian Henry
  • Start date Start date
B

Brian Henry

I wish someday they would add the ability to perform SQL commands on data
tables in ADO.net... it would make some stuff so much easier...
 
Brian Henry said:
I wish someday they would add the ability to perform SQL commands on data
tables in ADO.net... it would make some stuff so much easier...

Were you aware of the DataTable.Select method?

John Saunders
 
The problem with the DataTable.Select method is that it works on a single
datatable and is very poor in comparison to real SQL commands. Does anyone
knows about a way to run SQL commands on a dataset? I.e, to query the
in-memory dataset...

Thanks,
Arnon.
 
Arnon Axelrod said:
The problem with the DataTable.Select method is that it works on a single
datatable and is very poor in comparison to real SQL commands. Does anyone
knows about a way to run SQL commands on a dataset? I.e, to query the
in-memory dataset...

Sorry, you'll have to "roll your own', using DataTable.Select,
DataTable.Compute, DataRelations and adding computed columns.

It's usually better to let databases do the "database" work...

John Saunders
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top