Monday, March 19, 2012

Datareader and arrays

I have data I am retrieving using a datareader...and SQLSERVER
It could return 1 row of information or perhaps 3 rows of information
I need to know how to use an array here I would guess so I can access each element in this row or rows.

HOw might I use reader.read and get it into the arraywhy don't you just use a DataSet to hold the data, that's like one big smart array that holds everything.|||HOw might I create such a thing using a stored procedure that uses a join..I am confused on this dataset...Dont you have to set the default table or something.....

Any coding samples...
How do you move through a dataset|||it's all in ado.net docs somewhere, search for it, I'm sure you'll come up with something.

You'll need a Connection, then a Command, then a DataAdapter, then a DataSet.|||DATATABLE!