ADO.Net 2.0 and enhancements
The article compares ADO.Net 2.0 with 1.1 and lists down the enhancements for DataSet, DataTable and DataView classes.
Here are some of the new features in ADO.NET 2.0
- There has been a lot of performance
improvement working with DataSet in 2.0.
- Now one can serialize a DataSet into
binary data using ds.RemotingFormat
= SerializationFormat.Binary
- DataTable now supports ReadXML,
ReadXMLSchema, WriteXML and WriteXMLSchema methods.
- DataTable also includes 2 new methods
GetDataReader and Load. GetDataReader returns a DataTableReader which can
be used to iterate throw the rows just like SQLDataReader.
- Load method loads the table with
specified IDataReader parameter. The second parameter is LoadOption enum (OverwriteRow,
PreserveCurrentValues and UpdateCurrentValues). The article explains the
differece between these in an easy to understand way.
- DataView has a new method ToTable()
which returns DataTable object created out of the DataView.