Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert data from SQL database to a XML-file based on a DTD

Status
Not open for further replies.

hoocken

Programmer
Dec 15, 2006
2
SE
Hi,

Hope someone can help me.

The task.
I have a table in a SQL database with data which I want to extract into a
XML-file. I want the XML-file to follow a specific DTD which I also have.
How can I associate a specific column in the database to a specific element in the DTD?
For exampel:
I have three columns in man database table. ID, NAME and NUMBER.
I have a DTD which look like this (part of it)
<!ATTLIST allocation
ID CDATA #REQUIRED
NAME CDATA #REQUIRED
NUMBER CDATA #REQUIRED
>

How do I connect the database column ID with the ID in the DTD and then build a XML-file of it?

Regards
hoocken
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top