Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
11-16-2008, 07:54 PM #1
- Join Date
- Nov 2008
- Thanked 0 Times in 0 Posts
Constructing queries in XQuery on the basis a DTD
Ok i have been recently studying xpath but im a bit stumped on xquery.When writing queries do you write them in the same way as xpath or is it different?
I have been trying to answer these sample questions but have had no luck.
The question is:
The following DTD defines bibliographic information.
<!ELEMENT bib (book* )> <!ELEMENT book (title, (author+ | editor+ ), publisher, price )> <!ATTLIST book year CDATA #REQUIRED > <!ELEMENT author (last, first )> <!ELEMENT editor (last, first, affiliation )> <!ELEMENT title (#PCDATA )> <!ELEMENT last (#PCDATA )> <!ELEMENT first (#PCDATA )> <!ELEMENT affiliation (#PCDATA )> <!ELEMENT publisher (#PCDATA )> <!ELEMENT price (#PCDATA )>
Find all authors who have authored a book and an article in the same year.?
This was what i was given on the question and im stumped.
Can any one give me the answers/tips/hits on how to answer these.I think i just need the answer to one of them just to see what i should be doing.
Thanks in advance
Last edited by mattys1; 11-18-2008 at 04:14 PM.