What is the Internal Format of DataSet/DataReader?

  • Thread starter Thread starter MrBug
  • Start date Start date
M

MrBug

Hi All,

I am new in .net world.
few of my friend told me that internal data format of DataSet/DataReader is
XML only not the Binary format is that true ?

Thanks
Mr.Bug
 
A dataset is ultimately represented by XML, but I really doubt the same of a
DataReader. You can't take the contents of a DataReader and serialize them
to XML and then navigate through it, without iterating through it, and then
adding the items to something else like an Array or a DataTable so I think
it's state changes each time through. I'll look around though and make
sure.

HTH,

Bill
 
AFAIK DataReaders are using the low level protocol of the DBMS they are
targeting, for example TDS "Tabular Data Stream" for SQL Server.

Not really a client storage though as each line is read in turn and probably
forgotten once you advance (forward only resultset). Plus you don"t have
anyway access to this internal format.

It seems I remember that internally the XML tree uses some kind of
compression (though this is exposed anyway to the outside as "plain" XML).

Patrice

--
 
This is a common question and often answered incorrectly.

The DataReader returns the low-level data stream from the .NET data
provider. It is decoded by ADO.NET on a column-by-column basis using the
DataReader "Get" methods.

The DataAdapter Fill method uses a DataReader to construct an in-memory
DataSet, DataTable(s) and DataRows(s). NO, these are not stored as XML (that
would be very inefficient). The data is stored in linked arrays--one for
each column based on the datatype of the rowset column. If the application
wishes to extract or read the data in XML format, ADO.NET does so on the fly
as needed.

hth

--
____________________________________
Bill Vaughn
MVP, hRD
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 
Back
Top