Re: Store XML in a Database

From: Doyle (mypetrock_at_yahoo.com)
Date: 10/22/03


Date: 22 Oct 2003 10:26:10 -0700


"Stefan Garde" <stefangarde@hotmail.com> wrote in message news:<3f955ad5$0$54832$edfadb0f@dread11.news.tele.dk>...
> I need to figure out how you store a XML file (and its data) down in a
> Access database, by the help of SQL.

Do you need to just store the XML string or convert it into its
constituent parts and store it?

If you need to break it into its parts you should first figure out how
the XML file maps to the database. With any luck you should have some
level of entity/table mapping.

After loading your document into a XML-DOM parser with JAXP
(http://java.sun.com/xml/jaxp/index.html) or Xerces
(http://xml.apache.org/xerces2-j/index.html), you should be able to
recursively traverse your document. Once you are at the leaf nodes you
should be able to begin to enter the data into the database with
simple SQL statements.

I hope that is enough to get you started.

mypetrock



Relevant Pages

  • Re: Problems with querying date field
    ... >> If you want to put a database somewhere for safekeeping, ... database - SQL isn't about persistence, ... says nothing about the physical storage media to be used. ... store data on a tape, or a disk, or a CD, or a file, or any physical ...
    (microsoft.public.sqlserver.programming)
  • Re: Intranet Design Question
    ... "You don't actually have to use a database, you could store the info in an ... > link to the logon site. ... > an XML file since it would not have many columns. ...
    (microsoft.public.inetserver.iis.security)
  • Re: Storing docs in database vs storing in file system
    ... > the file system and simply keeping a pointer to each file in the database. ... I personally found the storage in sql method ... the files when they were stored in the directory structure. ... directory structure to store all the files. ...
    (microsoft.public.sqlserver.programming)
  • Re: How do you store .JPG in ACCESS using VB.NET
    ... I thought if I could find a solution hear in VBA land I could convert to .NET ... > You've mistakenly posted your question in the Microsoft Access (the database ... Jet SQL or any SQL dialect of the database server the front end is ... >>I have written a program to store images. ...
    (microsoft.public.access.modulesdaovba)
  • Re: Sharepoint Installation MSDE Location Question
    ... I want to host the SQL Server and WSS on the ... and I want to store the SQL database on a storage array ...
    (microsoft.public.sharepoint.windowsservices)