 |
| SQL Server 2005 General discussion of SQL Server *2005* version only. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the SQL Server 2005 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

August 29th, 2006, 11:24 AM
|
|
Registered User
|
|
Join Date: Aug 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
XML SIZE LIMIT
Hi,
In the book "SQL Server 2005 XML", it say one of the limitations of SQL XML is that the xml data type instance can not exceed 2GB. Does't it mean that one colum in a table can not exceed 2GB or one row that have xml column can not exceed 2GB (individual document).
Thanks,
Anourak
|
|

August 29th, 2006, 03:32 PM
|
 |
Wrox Author
|
|
Join Date: Dec 2004
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
|
|
Hi Tristany,
In BOL it states the following:
"The xml data type lets you store XML documents and fragments in a SQL Server database. An XML fragment is an XML instance that is missing a single top-level element. You can create columns and variables of the xml type and store XML instances in them. Note that the stored representation of xml data type instances cannot exceed 2 GB."
Hope this helps...
Scott
|
|

August 30th, 2006, 11:48 AM
|
|
Registered User
|
|
Join Date: Aug 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi,
I'm still confuse, sorry... When you say "xml data type instances cannot exceed 2 GB", you mean one column XML can not exceed 2GB or one document in the XML column can not exceed 2GB...
Thanks,
Anourak
|
|

August 30th, 2006, 01:36 PM
|
 |
Wrox Author
|
|
Join Date: Dec 2004
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
|
|
Hi Anourak,
That means that the size of the xml document in the xml data type column cannot exceed 2GB.
Scott
|
|

September 12th, 2006, 09:04 AM
|
|
Registered User
|
|
Join Date: Aug 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Thanks for the answer,
Right now I created a small web application(Questionnaire document) that store all the field in the xml data type. I just want to know if it is a good idea to store every field in xml format. Like that the client can add or delete any field they want. Right now the xml web application is working fine, but xml data type is so new that I'm questioning about the reliability.
thanks,
Anourak
|
|

September 12th, 2006, 09:32 AM
|
 |
Wrox Author
|
|
Join Date: Dec 2004
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
|
|
Well, I don't know if I would store EVERY field in xml format. From a reliability perspective, I would not hesitate to use it. Microsoft put a lot of thought and work into support XML. However, you have to ask yourself some questions. A relational model will work if your data is structured and has a known schema. XML works well if your data is not structured (meaning, you don't know the stucture of the data) or if the structure of the data is not consistent (changes often).
Look in the SQL Server 2005 Book Online under XML best practices. It does a very good job laying out the options available to you as to when to use a relational model and when to use XML data type.
|
|

September 14th, 2006, 08:58 AM
|
|
Registered User
|
|
Join Date: Aug 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
The meaning that I store the entire field in XML format is because the client can create a fast web application. They don't need to create a table... It is very resemblance then the Lotus Notes application. In my understanding, Notes document is an XML. Of course, Notes have a size limit for one database. In SQL server, the XML documents can not exceed 2GB. I hope that XQUERY, is powerful enough to do a complex reports.
Thanks
Anourak
|
|

September 14th, 2006, 01:01 PM
|
 |
Wrox Author
|
|
Join Date: Dec 2004
Posts: 338
Thanks: 0
Thanked 2 Times in 2 Posts
|
|
XQuery in SQL Server 2005 is very good. I have not used it against extremely large documents, so I would be interested in hearing how it performs on the type and size of documents you are talking about.
|
|
 |