473,667 Members | 2,577 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How is DataSet class implemented

I heard somewhere that the DataGrid class is implemented as a XML graph in
memory. Is this true ?

TIA
Boaz Ben-Porat
DataPharm a/s
Denmark
Nov 15 '05 #1
6 2663

Hi Boaz,

The dataset class can be easily display as a xml graph, you can just
display it like this:
Console.WriteLi ne( ds.GetXml() );
Also, dataset can manipulate the xml file freely by writexml method

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: "Boaz Ben-Porat" <bo***@dataphar m.dk>
| Subject: How is DataSet class implemented
| Date: Wed, 1 Oct 2003 17:19:16 +0200
| Lines: 9
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
| Message-ID: <OC************ **@TK2MSFTNGP11 .phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.csharp
| NNTP-Posting-Host: 195.215.64.74
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.csharp:1883 93
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.csharp
|
| I heard somewhere that the DataGrid class is implemented as a XML graph in
| memory. Is this true ?
|
| TIA
| Boaz Ben-Porat
| DataPharm a/s
| Denmark
|
|
|

Nov 15 '05 #2
Thanks Jeffry

My question is:
Is Reading and manipulating data in DataSet more effective or less effective
then reading and mnipulating in custom developed objects. If DataSet IS
implemented as one large XML document in RAM then I suspect it is NOT the
most effective structure. Am I right ?

TIA
Boaz Ben-Porat
DataPharm a/s
Denmark

"Jeffrey Tan[MSFT]" <v-*****@online.mi crosoft.com> skrev i en meddelelse
news:vx******** ******@cpmsftng xa06.phx.gbl...

Hi Boaz,

The dataset class can be easily display as a xml graph, you can just
display it like this:
Console.WriteLi ne( ds.GetXml() );
Also, dataset can manipulate the xml file freely by writexml method

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: "Boaz Ben-Porat" <bo***@dataphar m.dk>
| Subject: How is DataSet class implemented
| Date: Wed, 1 Oct 2003 17:19:16 +0200
| Lines: 9
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
| Message-ID: <OC************ **@TK2MSFTNGP11 .phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.csharp
| NNTP-Posting-Host: 195.215.64.74
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.csharp:1883 93 | X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.csharp
|
| I heard somewhere that the DataGrid class is implemented as a XML graph in | memory. Is this true ?
|
| TIA
| Boaz Ben-Porat
| DataPharm a/s
| Denmark
|
|
|

Nov 15 '05 #3
What I heard is that DataSet is ACTUALLY implemented as a XML graph in
RAM, and thus ineffective when used to other operations then direct data
manipulation.

We are at the design phase of a very large system, to be implemented in
C#/.NET. We should generate (automatically) a datatype for each
table/view/stored-procedure(proc` s result set). The easiest way is to
generate a typed DataSet for each object (This can be done with 10 line
of code.

Anotehr soloution is to write a code generator that creates a C# class
for each such object. My company has experince with this.

These objects, either custom objects or Typed DataSet (where DataRow is
the base object) are used for wide range of manipulations.

The Question:
-------------
Is DataSet effective in such scenario ?
If it is an XML graph in RAM then I suspect it is NOT effective.

Any advise ?

TIA
Boaz Ben-orat
DataPharm a/s
Denmark

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 15 '05 #4
Hi Boaz,

I don't think so, that the dataset can be represented as a XML document has
nothing to do with its internal way to keep the data once it's readed from a
XML file. You can take a look at the .net source ( I don't remember where
you can get them, I will let you know if I remember) and see how the DataSet
is implemented.
Cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"Jeffrey Tan[MSFT]" <v-*****@online.mi crosoft.com> wrote in message
news:vx******** ******@cpmsftng xa06.phx.gbl...

Hi Boaz,

The dataset class can be easily display as a xml graph, you can just
display it like this:
Console.WriteLi ne( ds.GetXml() );
Also, dataset can manipulate the xml file freely by writexml method

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: "Boaz Ben-Porat" <bo***@dataphar m.dk>
| Subject: How is DataSet class implemented
| Date: Wed, 1 Oct 2003 17:19:16 +0200
| Lines: 9
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
| Message-ID: <OC************ **@TK2MSFTNGP11 .phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.csharp
| NNTP-Posting-Host: 195.215.64.74
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.csharp:1883 93 | X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.csharp
|
| I heard somewhere that the DataGrid class is implemented as a XML graph in | memory. Is this true ?
|
| TIA
| Boaz Ben-Porat
| DataPharm a/s
| Denmark
|
|
|

Nov 15 '05 #5
Does it matter how it is implemented? Test both methods and compare the difference, if the dataset does use xml underneath but is
somehow more efficient then it doesn't really matter.

--
Michael Culley
"Boaz Ben-Porat" <bo***@dataphar m.dk> wrote in message news:eW******** ******@TK2MSFTN GP10.phx.gbl...
What I heard is that DataSet is ACTUALLY implemented as a XML graph in
RAM, and thus ineffective when used to other operations then direct data
manipulation.

We are at the design phase of a very large system, to be implemented in
C#/.NET. We should generate (automatically) a datatype for each
table/view/stored-procedure(proc` s result set). The easiest way is to
generate a typed DataSet for each object (This can be done with 10 line
of code.

Anotehr soloution is to write a code generator that creates a C# class
for each such object. My company has experince with this.

These objects, either custom objects or Typed DataSet (where DataRow is
the base object) are used for wide range of manipulations.

The Question:
-------------
Is DataSet effective in such scenario ?
If it is an XML graph in RAM then I suspect it is NOT effective.

Any advise ?

TIA
Boaz Ben-orat
DataPharm a/s
Denmark

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 15 '05 #6
Boaz,
As Ignacio stated, the DataSet is not implemented internally as one large
XML document.

It is implemented as a collection of DataTable objects, DataTables are
implemented as a collection of DataColumn & DataRow objects. DataRow objects
are implemented as an array of System.Object objects.

Remember when you put value types into a Sytem.Object you need to box &
unbox them, so there is a performance hit there. Also the fact the DataRow
has an array of them, there is a second hit.

If by "custom developed objects" you mean a formal domain model, I would
expect the formal domain model to be more performant as it should be doing
less boxing & unboxing and have fewer collections.

David Sceppa's book "Microsoft ADO.NET - Core Reference" from MS Press
covers all aspects of DataSets and how they are organized.

Martin Fowlers book "Patterns of Enterprise Application Architecture" from
Addison Wesley provides a number of patterns for getting data from a
database to & from your domain model & patterns on using DataSets verses
domain models.

Rockford Lhotka's book "Expert One-on-One Visual Basic .NET Business
Objects" from APress (formally from Wrox) provides the CSLA.NET framework
which gives you the flexibility of a DataSet while defining a formal Domain
Model.

Hope this helps
Jay
"Boaz Ben-Porat" <bo***@dataphar m.dk> wrote in message
news:eC******** ******@TK2MSFTN GP12.phx.gbl...
Thanks Jeffry

My question is:
Is Reading and manipulating data in DataSet more effective or less effective then reading and mnipulating in custom developed objects. If DataSet IS
implemented as one large XML document in RAM then I suspect it is NOT the
most effective structure. Am I right ?

TIA
Boaz Ben-Porat
DataPharm a/s
Denmark

"Jeffrey Tan[MSFT]" <v-*****@online.mi crosoft.com> skrev i en meddelelse
news:vx******** ******@cpmsftng xa06.phx.gbl...

Hi Boaz,

The dataset class can be easily display as a xml graph, you can just
display it like this:
Console.WriteLi ne( ds.GetXml() );
Also, dataset can manipulate the xml file freely by writexml method

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
--------------------
| From: "Boaz Ben-Porat" <bo***@dataphar m.dk>
| Subject: How is DataSet class implemented
| Date: Wed, 1 Oct 2003 17:19:16 +0200
| Lines: 9
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
| Message-ID: <OC************ **@TK2MSFTNGP11 .phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.csharp
| NNTP-Posting-Host: 195.215.64.74
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.csharp:1883 93
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.csharp
|
| I heard somewhere that the DataGrid class is implemented as a XML

graph in
| memory. Is this true ?
|
| TIA
| Boaz Ben-Porat
| DataPharm a/s
| Denmark
|
|
|


Nov 15 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1971
by: Frosty | last post by:
Hi I am using the VS xsd designer to create a strongly typed dataset. The dataset is apparently successfully created, with no warnings or errors given. Is it not then to be expected that this dataset then should reflect all the details put into the xsd? Somewhere down the line there is not a 1:1 relationship. Be it that .NET is so tightly coupled to xsd, xml and dataset I would have expected any discrepancies to have been well documented and...
2
13052
by: JS | last post by:
I'm trying to create a data layer and having problems returning a DataSet from my code that's in a class module. Please forgive me. I'm new to C# (VB'er). I decided to create my data layer in small steps. Right now, I'm just trying to attach a ComboBox to a dataset that's in my class module. In the class, I call a Stored Procedure. I know how to set up the connection, command, adapter, and dataset, what I'm having a problem with is,...
3
2949
by: news.microsoft.com | last post by:
The question is, is a DataSet CLS compliant? Minimally implemented code, with an attribute in the assemblyinfo.cs compiles just fine (is it possibly the data INSIDE the dataset that could invalidate its compliancy?): using System; using System.Data; namespace ConsoleApplication1
2
2351
by: ofer | last post by:
Hi, I am working with the beta version of the new .net framework (Whidbey) and I encountered a problem with serialization that did'nt exist in the .net 2003 the situation is like this : I have a class that inherits from dataset, and I want to serialize it , so I created a serialization constructor that forwards the call to the base class (the dataset) serialization constructor, normally, for this action to succeed I am supposed to put...
9
2265
by: Dave | last post by:
Compilier will not recognize DataSet object. As you can see below is from a test simple form with no other code. I'm just trying to get any Aspx form to recognize the DataSet object. You can see from the code I am importing System.Data.SqlClient. I can get to DataReader, DataView and DataTable but Visual Studio won't even bring up DataSet on Intellisense, much less compile it. The message I get is: "Reference required to assembly...
2
1168
by: Gary Shell | last post by:
I have jumped in to the deep end of the pool, trying out visual inheritance of a form and have run into a snag. I have the need to create a simple maintenance form for five identically configured database files. (The only difference in the tables is their name and keyfield name.) Hmmm, I though, a perfect candidate for trying our Visual Inheritance for the first time. ARGHHHHHHH! What have I gotten myself into? Here's the...
17
3433
by: Modica82 | last post by:
Hi All, I am very new to web services, so am struggling to understand exactly what I am doing with regards to its returns etc. I have been given the task of designing and developing a web service which will allow external companies, access to our information. The problem for me is that these companies will be using different platforms from which to consume our web service. My question is what I should use as the return type for more...
15
13502
by: Joseph Geretz | last post by:
I'm a bit puzzled by the current recommendation not to send Datasets or Datatables between application tiers. http://support.microsoft.com/kb/306134 http://msdn2.microsoft.com/en-us/library/ms996381.aspx Formerly, with classic Microsoft DNA architecture, the ADO Recordset was a primary transport medium, recommended for transmitting data between application tiers. In fact, there are whole books written on the subject.
5
1697
by: Tony Johansson | last post by:
Hello! Xml is used havily when dealing with DataSet. I know that Xml schema is used by DataSet. Xml schema is used to verify the structure of an Xml document. So does this mean that a DataSet is using Xml document internally ? //Tony
0
8457
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8365
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8883
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8788
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8646
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6203
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5675
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4372
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1778
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.