O'Reilly logo

ASP.NET for Web Designers by Peter Ladka

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Querying Data

You will most often be trying to pull data out of your data source to display it on your ASP.NET pages. To do so, you would use a SQL Select statement. In these examples, the Northwind database is the data source and a DataReader is populated with the results of the SQL command.

DataReader

Remember, a DataReader is a forward-only group of rows of data. You can iterate through the DataReader to display its contents with the DataReader’s Read() method, and you can find many examples of that in the SDK. I’ve also read that many sources are saying that a DataReader cannot be databound to the server controls you saw in the last chapter. I have not found that to be the truth, and I stand as the shining light in the darkness of misinformation. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required