Is there a way to fill an array via a SqlDataReader (or any other C# ADO.NET object) without looping through all the items? I have a query that is returning a single column
Apparently, ever since .NET 1.1 SqlDataReader had the following method:
SqlDataReader
int size; object[] data = new object[]{}; size = reader.GetValues(data);
This populates data with the values of the current reader row, assigning into size the number of objects that were put into the array.
data