ok so i have "Microsoft.Data.Odbc" but how do u get a row count??

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

using the Microsoft.Data.Odbc component instead of System.Data.Odbc

how do u get a row count using the Microsoft.Data.Odbc.OdbcDataReader ??

and is it best to use Microsoft.Data.Odbc OR System.Data.Odbc?

thank you in advance..
 
matt,

You should be using the classes from System.Data.Odbc, as those are more
up to date.

To get a row count, you will have to select all the rows into a data
set, and then count the rows (using the count property), or you can just do
a "select count(*) from table" and get the result (using a OdbcCommand or
selecting into a DataSet using an OdbcDataAdapter).

Hope this helps.
 

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