|
|
|
SSC Eights!
      
Group: General Forum Members
Last Login: 2 days ago @ 10:30 AM
Points: 963,
Visits: 347
|
|
I don't think the purpose of this particular use of XML is to make it meaningful. It is used as a method to transport data. For the purposes of this demo, the author takes a clean approach and concisely shows how to accomplish the task. I would object to taking this approach in the real world, however. It is a small point, but worthy of consideration IMHO: if the insert fails in such a way that the sproc aborts, you leave an open XML document with no handle available. If this happens enough times you will exhaust the "MEMTOLEAVE" area and be forced to restart your SQL server. I would load the XML into a temporary table, destroy the XML document, and then perform the insert, perhaps after validating the data. This is a good article and it demonstrates a reasonable use of XML in the database.
|
|
|
|
|
SSCertifiable
       
Group: General Forum Members
Last Login: Tuesday, May 14, 2013 4:39 PM
Points: 6,260,
Visits: 1,977
|
|
I think the article was clear and very to the point but besides the advantages of using this technique the drawbacks should also be pointed out. I have had memory issues with openxml in the past even though it seems like a nice tool for the job. MSXML parser is an out-of-process memory intense component and you should be really careful on highly transactional environments.
* Noel
|
|
|
|
|
SSC-Addicted
      
Group: General Forum Members
Last Login: Saturday, May 11, 2013 8:17 AM
Points: 460,
Visits: 2,521
|
|
As I mentioned earlier, the last part of this 4 part article has an error handling example, where the XML handle is released if an error occurs.
.
|
|
|
|
|
SSC Eights!
      
Group: General Forum Members
Last Login: 2 days ago @ 10:30 AM
Points: 963,
Visits: 347
|
|
Hi jacob, That's what I get for attempting comprehension before the coffee kicks in.
|
|
|
|
|
SSC-Addicted
      
Group: General Forum Members
Last Login: Saturday, May 11, 2013 8:17 AM
Points: 460,
Visits: 2,521
|
|
.
|
|
|
|
|
Forum Newbie
      
Group: General Forum Members
Last Login: Wednesday, July 25, 2007 8:35 AM
Points: 3,
Visits: 1
|
|
Your article is very interesting from the viewpoint of presenting a different way to deal with the classic order entry problem. However, it would be useful if you would show some timings for the old way vs. the new way. Specifically: What is the elapsed time for a single order from a single client? How does the time degrade as the number of users/orders increases? What is the cost to the SQL Server for each method (CPU, Duration, Reads, Writes)? How does that change as the number of transactions increases? Again, the technique is interesting, but I think you should show how it compares to the "standard" method from a timing and resources point of view.
|
|
|
|
|
SSC-Addicted
      
Group: General Forum Members
Last Login: Saturday, May 11, 2013 8:17 AM
Points: 460,
Visits: 2,521
|
|
Hi Paul, I will definitely collect some performance data and will post it soon. Jacob
.
|
|
|
|
|
SSCrazy
      
Group: General Forum Members
Last Login: Yesterday @ 8:46 AM
Points: 2,750,
Visits: 1,410
|
|
The bit that concerns me is the BOL entry that warns that this takes 1/8th of the server memory. So a 16GB box is going to lose 2GB RAM just for opening a World document.
In SQL2000 I'm pretty sure that the XML parser is MSXML3 where as the most up-to-date version is MSXML6.0.
It's a shame because its an elegant solution let down by the underlying technology.
LinkedIn Profile
|
|
|
|
|
Forum Newbie
      
Group: General Forum Members
Last Login: Wednesday, April 04, 2007 1:00 PM
Points: 4,
Visits: 1
|
|
This article is clean and clear. I hope there is a part two that will shed more light on related topics. This would be very helpful for a DBA greener like me. Thanks. Amarado
|
|
|
|
|
Forum Newbie
      
Group: General Forum Members
Last Login: Wednesday, July 25, 2007 8:35 AM
Points: 3,
Visits: 1
|
|
Amarado, I found (by accident) that if you go to the top of this page and click on "Next Topic" it will take you to what appears to be all of the articles in this series. Look quick before they change it!
|
|
|
|