For practical exercises, the XML software will be installed in the IFI CIP Pool.
/afs/informatik.uni-goettingen.de/course/xml-lecture/XML-DTD
/afs/informatik.uni-goettingen.de/course/xml-lecture/XML-DTD
xmllint -shell mondial-europe-2.0.xml
pwd
cat //country
cat //country/name
cat //country[name="Germany"]
cd //country[name="Germany"]
pwd
cd province[9]
du
cat name
dir
cd id('cty-Germany-Hannover')
cat
pwd
saxonXQ -dtd:on -s:mondial.xml bla.xq
<!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!ELEMENT html (head, body)>
<!ATTLIST html
xmlns %URI; #FIXED 'http://www.w3.org/1999/xhtml'
>
(see comments on querying XHTML below for the consequences of this).
saxonXQ "{doc('/afs/informatik.uni-goettingen.de/course/xml-lecture/Mondial/mondial.xml')//country/name}"
saxonXQ "{doc('http://www.dbis.informatik.uni-goettingen.de/Mondial/mondial.xml')//country/name}"The following aliases should be set in the file .bashrc:
alias saxonXQ='java -cp /afs/informatik.uni-goettingen.de/group/dbis/public/saxon/saxon8.jar net.sf.saxon.Query'
alias saxonXSL='java -cp /afs/informatik.uni-goettingen.de/group/dbis/public/saxon/saxon8.jar net.sf.saxon.Transform'Call saxonXQ filename.xq to execute an XQuery (or XPath query) from a file. The query in filename.xq must address a document by using the
saxonXQ -s /afs/informatik.uni-goettingen.de/course/xml-lecture/Mondial/mondial.xml filename.xqThus, it is not necessary to specify the document in the query file. This can also be specified as an alias:
alias saxonXQMondial='saxonXQ -s /afs/informatik.uni-goettingen.de/course/xml-lecture/Mondial/mondial.xml'
Download: Download Saxon, unpack it, set CLASSPATH accordingly, set aliases for saxon-XQuery and saxon-XSL accordingly.
The XQuery-Demo WebService. This WebService also uses Saxon internally.
The WebService is also available for local installations at
/afs/informatik.uni-goettingen.de/course/xml-lecture/XML-Tools/xquery-demo.warIt can be used with any standard web application server, e.g. tomcat.
/afs/informatik.uni-goettingen.de/course/xml-lecture/XMLSchema/mondial.xsd
There is an Oracle instance accessible from the CIP-Pool. Use the global alias command sqlap34 for logging into a dummy account (one account for all).
Please do not change the mondial tables (otherwise, start @consult and re-create the respective table). The user is allowed to create tables and views - please identify everything you create by your name (e.g. CREATE TABLE MAY_COUNTRY (...)) and delete it if you don't need it any more.