Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

What does an executereader return?

Posted on 2006-11-06
6
Medium Priority
?
678 Views
Last Modified: 2008-03-06
What does an executereader return?
0
Comment
Question by:mathieu_cupryk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 15

Expert Comment

by:ozymandias
ID: 17884817
A DataReader
0
 

Author Comment

by:mathieu_cupryk
ID: 17885974
...a single value.
 
 
--------------------------------------------------------------------------------
 
  ...an XML DataSet.
 
 
--------------------------------------------------------------------------------
 
  ...a rowset.
 
 
--------------------------------------------------------------------------------
 
  ...nothing as there is no value to return.
 
0
 

Author Comment

by:mathieu_cupryk
ID: 17885976
which of the four?
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 2

Accepted Solution

by:
Sinclair earned 750 total points
ID: 17886036
Technically, it does return a single value, just like every other function in C#. heh heh heh.
0
 
LVL 15

Expert Comment

by:ozymandias
ID: 17887468
It returns a class derived from DataReader depending on the type of the Command, i.e. an OdbcCommand.ExecuteReader() returns an OdbcDataReader.
The best answer is probably a rowset.
0
 
LVL 2

Expert Comment

by:Sinclair
ID: 17887522
It's kind of a pointless question, though, even for an "Intro to C#" course. All you need to do is memorize the right keywords, and you pass... but... that doesn't actually teach you anything. If they asked, "how many rows is the DataReader guaranteed to contain", or "which row is the DataReader's internal pointer pointing to immediately after the method returns", that would at least be something. But even then, who cares ? All that info is in the API comments, it doesn't take too long to look it up.

Sorry, I know that was offtopic, I just find CS classes like this one really frustrating :-(
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question