Answer Posted / anup kumar
yes, it is posible. by using NextResult() method of
sqldatareader.
sqlcommand cmd = new sqlcommand("select id from emp ; select
dptid from dpt",YourConnection);
//check connection status and open the connection
if(rdr.hasrows)
{
//read id from emp
}
if (rdr.HasRows() == true)
{
//read dptid from dpt
}
//close the connection
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Define connection string?
Which is the best method to get two values from the database?
Which is faster ado.net or linq?
What is ado.net and its architecture?
What are the different ado.net namespaces?
Which one of the objects is a high-level abstraction of the connection and command objects in ado.net?
Explain the various objects in dataset.
What is a sqldataadapter?
How is entity framework different from ado.net?
What is the default provider in ado.net?
How to store data in memory?
What is ado.net and its features?
Define bubbled event?
What is the difference between ADO and ADO.Net?
How to perform sorting on a table in ADO.NET?