473,326 Members | 2,255 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

XML Serialization / Datasets

Hi There.

This post is a extension of thread "Serialize or not to Serialize", on 5 of
December of 2006.

The reason why my teacher insists that a WS cannot return a Dataset is due
to low rate networks, not due to SOAP schemas. I think that's because a XML
Dataset is too large.

So, in my WS, I want to turn my dataset in some type of class, and then send
the client an array of this class elements. Even so, I don't know if this is
a good idea. What if this class has hundreds or thousands of elements? Isn't
that too large also? I looking for a way to send the data in small portions,
but I don't know how... :(

Thanks for your answers.

Paez
Dec 8 '06 #1
1 2188
Hi Paez,
The reason why my teacher insists that a WS cannot return a Dataset is due
to low rate networks, not due to SOAP schemas. I think that's because a
XML
Dataset is too large.
The size of the SOAP envelope is irrelevant, AFAIK.

It's the schema that makes DataSets seems so large when serialized as xml.
For very small DataSets (in schema and size), the schema might appear to be
half of the entire xml content or more; however, the schema size is a
constant, so as the DataSet scales the schema won't change. If you're
serializing thousands of records, the size of the schema won't make any
difference at all. The size of the actual DataSet content is comparable to
that of a custom collection containing instances of a custom class.

In a Typed DataSet, there is more meta-data per row when it's serialized
than in an untyped DataSet or a custom class. I think this is where that
"DataSets are too big to be serialized as xml" axiom comes in to play.

If you can get away without using a Typed DataSet (which makes sense in a
public Web Service that may be consumed by many different platforms other
than just .NET) then I think you'll find that the amount of data produced
after serialization between an untyped DataSet and a custom class is
comparable.
So, in my WS, I want to turn my dataset in some type of class, and then
send
the client an array of this class elements. Even so, I don't know if this
is
a good idea. What if this class has hundreds or thousands of elements?
Isn't
that too large also? I looking for a way to send the data in small
portions,
but I don't know how... :(
The data has to get there one way or another, so sending them in smaller
pieces isn't going to reduce the overall amount of data that needs to be
sent. Actually, when speaking of xml serialization and SOAP, it will
probably end up being larger than if you were to just make a single method
to send all of the data at once, using a simple class architecture or
untyped DataSet.

--
Dave Sexton
Dec 9 '06 #2

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

Similar topics

3
by: Aaron Clamage | last post by:
Hi, I'm not sure that if this is the right forum, but any help would be greatly appreciated. I am porting some java serialization code to c# and I can't figure out the correct way to do it. ...
1
by: Dan | last post by:
Hello, I am having trouble serializing a typed dataset that has a number of expression columns. When I attempt to serialize the dataset, the framework (.NET 1.1) throws a NullRefException. ...
4
by: Brian Keating | last post by:
wonder if anyone can help me here, i've a framework 1.1 dataset which i serialize in framework 1.1 and deserialize in framework 2.0. This is fine, problem is that i want to modify some of the...
4
by: Alpha | last post by:
I have a small Window application and through out the different forms I create a different dataset. At the begining I used the Tools to drag and drop the SqlDataAdapter, connection and dataset...
2
by: Wild Wind | last post by:
Hello, I have an object which has various properties, including one which is of type DataSet. I need to serialize this object in binary format, but I've discovered that the BinaryFormatter...
0
by: Philp | last post by:
I have a problem with the serialization of datasets when they are strongly typed? I am not sure where I would go to set an attribute to serialize the ds since it really does not have a view in the...
1
by: kikisan | last post by:
I am developing a windows service which utilizes the following classes: interface IPersistable; abstract class PersistableObject : IPersistable;
2
by: mkvenkit.vc | last post by:
Hello, I hope this is the right place to post a question on Boost. If not, please let me know where I can post this message and I will do so. I am having a strange problem with std::string as...
12
by: BillE | last post by:
I'm trying to decide if it is better to use typed datasets or business objects, so I would appreciate any thoughts from someone with more experience. When I use a business object to populate a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.