What is the logic of storing XML in a Database?



X-No-Archive:yes

I see people putting XML documents in databases. Why do they do this,
what is the logic behind it? Why not just put the data into tables?
Why are the standards committees going along with this (XML SQL/
MED)? Why don't people just use tables to store the data thusly:

CREATE TABLE FOO_CUSTOMER
(
name VARCHAR
address VARCHAR
key INT
);

why are they doing this:

CREATE TABLE BAD_XML_CUSTOMER
(
customer_data XML

);

.



Relevant Pages

  • Re: Weird ADO error, any ideas?
    ... If the field causing the trouble is varchar, it doesn't seem someone would store extended ascii characters there, and it may be that what got into that field are remains of the connector and processor errors of the XML feed. ...
    (microsoft.public.vb.general.discussion)
  • Re: how to insert xml into sql 2005
    ... For right now I just know I have to get this into the sql database. ... to the contents of a SQL Server database. ... to XML processing no matter how big the XML document is. ... ,captionnohtml varchar 'CaptionNoHTML' ...
    (microsoft.public.sqlserver.xml)
  • Re: how to insert xml into sql 2005
    ... For right now I just know I have to get this into the sql database. ... to XML processing no matter how big the XML document is. ... ,captionnohtml varchar 'CaptionNoHTML' ...
    (microsoft.public.sqlserver.xml)
  • Re: nvarchar max
    ... Yes, SQL FTS supports char, nchar, varchar, nvarchar, varchar, ... nvarchar, image, varbinary and xml. ...
    (microsoft.public.sqlserver.fulltext)
  • Re: how to insert xml into sql 2005
    ... For right now I just know I have to get this into the sql database. ... The second one is how can I automation the xml import ever evening. ... ,captionnohtml varchar 'CaptionNoHTML' ... ,options varchar 'Options' ...
    (microsoft.public.sqlserver.xml)

Loading