Hi, I am trying to insert primary and foreign keys in a XSD schema. I have been able to create the two attached files in which students, addresses and a student/address relationship are defined.
An example of a student and address elements is:
====
<Student>
<Title>Title1</Title>
<FirstName>FirstName1</FirstName>
<LastName>LastName1</LastName>
<Dateborn>1900-01-01</Dateborn>
<Gender>Gender1</Gender>
<StudentID>StudentID2</StudentID>
<AddressID>AddressID1</AddressID>
</Student>
<Address>
<AddressID>AddressID1</AddressID>
<Street>Street1</Street>
<City>City1</City>
<Province>Province1</Province>
<Country>1900-01-01</Country>
<PostalCode>PostalCode1</PostalCode>
</Address>
================
Now, I would like to use as key not "AddressID" but the pair ("Street","City")
How should I modify the xsd file?
Thnaks in advance
Roberto
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <!-- Sample XML generated by QTAssistant (http://www.paschidev.com) --> <World xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <Student> <Title>Title1</Title> <FirstName>FirstName1</FirstName> <LastName>LastName1</LastName> <Dateborn>1900-01-01</Dateborn> <Gender>Gender1</Gender> <StudentID>StudentID1</StudentID> <AddressID>AddressID1</AddressID> </Student> <Student> <Title>Title1</Title> <FirstName>FirstName1</FirstName> <LastName>LastName1</LastName> <Dateborn>1900-01-01</Dateborn> <Gender>Gender1</Gender> <StudentID>StudentID2</StudentID> <AddressID>AddressID1</AddressID> </Student> <Address> <AddressID>AddressID1</AddressID> <Street>Street1</Street> <City>City1</City> <Province>Province1</Province> <Country>1900-01-01</Country> <PostalCode>PostalCode1</PostalCode> </Address> <Address> <AddressID>AddressID2</AddressID> <Street>Street1</Street> <City>City1</City> <Province>Province1</Province> <Country>1900-01-01</Country> <PostalCode>PostalCode1</PostalCode> </Address> </World>
s.xsd
Description: Binary data
--------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
