Click here to Skip to main content
15,914,010 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more: , +
hi all,

i am having one dataset with values in that. i need get some data from that dataset by using ds.select () method in that how to use count (*) with where condition

thanks in advance
Posted
Comments
ZurdoDev 28-Feb-12 11:50am    
Please explain more clearly what you want. You just want a count of records in the dataset?

DataSet is a container for DataTables, the each row of your DataTable is held in the DataRowCollection, which is the Rows property of the DataTable.

The beloe code helps you to fetch row count of the specified dataset named 'ds'

C#
ds.Tables("mytable").Rows.Count
 
Share this answer
 
SQL
thanks for reponse. but my quesition is how we use

suppose i have total table survey  in one dataset. i need to get below query

 select  distinct EmpRacfid from Survey  how can i get in dataset.select  method
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900