OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   database primary keys in XML Schema

[ Lists Home | Date Index | Thread Index ]

Hello everybody,

I am developing a XML Schema which should function as an interface to a
relational database.
I have problems with how to design the primary keys in XML Schema.

1.) When I insert data via XML instance documents the first time, I cannot
specify a primary key in my XML instance document because the database
automatically creates an auto-increment key. Correct?

2.) What if I, for example, want to insert a city in a geography database
(the database has a Country and a City table; 1:n relationship). When inserting
a city, how can I specify to which country the city belongs? I needed to
know the database primary key for the country, wouldn't I and add this key as an
attribute to the city in my instance document?
What other solutions do exist?

This issue cost me alot of time so far and I would really appreciate any
help!

Thanks a lot, Markus





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS