If you are using two select queries and retrieving data. how
do you access second query's result set using data reader?






If you are using two select queries and retrieving data. how do you access second query's resu..

Answer / uday kumar vuriti

If we have 2 select queries as follws
select * from dept
select * from emp

SqlDataReader dr;

//To Read 1st Select query dept
dr.Read();

//To Read 2nd Select query emp
dr.NextResult();

So the answer is dr.NextResult();

Is This Answer Correct ?    27 Yes 0 No

Post New Answer




More ASP.NET Interview Questions

You have two buttons in web form and i clicked on one of the button, so how do i find which button i've clicked on the form in my page load?

15 Answers   INDUS,


Differences between VB.Net and C#, related to OOPS concepts

5 Answers   CSC,


what is webpart? what r the parts in this webpart (zone)

2 Answers  


What is the difference between Server.Transfer and Response.Redirect?

5 Answers  


how to increase performance of web site? if there is a page with high load. the content is high then what should we do to increase performance?

3 Answers   Mphasis, Emphasis, TCS,






Write some code using interfaces, virtual methods, and an abstract class`

0 Answers  


how we Creating a Web Service

1 Answers   Mind Tree,


What are the types of authentications in ASP.NET?

2 Answers   Accenture,


What is the use of @Register directives?

3 Answers  


how can we create wcf in asp.net and how can we cll that in to asp.net application?plsss tel me each step clearly

0 Answers  


Hi , I am Basha. I am searching a job in dotnet.Plz tell me the order of page events in asp.net 2.0> plz send faq's related to c#.net,asp.net,sqlserver2000 etc. to my mail-id : bashask.ss@gmail.com

4 Answers   Sapient,


About DataAdapters ?

8 Answers   Accenture,






Categories