Well, using DataTable does not preclude use of LINQ
table.Rows.Cast<DataRow>() //IEnumerable<DataRow>, linq it to death
This guy makes some arguments about HashTable
vs. DataTable
and this guy finds Dictionary
better than DataTable
, but not by much (factors in Dictionary create cost).
Note: if the columns are known beforehand (that is, a user may select some of the columns from a predefined set of columns(name, type)), I would go with strongly typed classes, since data["property"]
does not get Intellisense support like data.Property
does.
bottlenecked
2010-06-07 11:53:23