[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
XQuery in XML syntax...
- To: cse494-s07@parichaalak.eas.asu.edu
- Subject: XQuery in XML syntax...
- From: "Subbarao Kambhampati" <rao@asu.edu>
- Date: Mon, 16 Apr 2007 07:33:34 -0700
- Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:mime-version:content-type:x-google-sender-auth; b=B73jY52KuY+Bd9DENMJJapsLGBqMNbviANCNE9DlKgT2oQvW2rSFeD96au+OMyE0fFHmI8U00r3GIfAKUqQhOmWE2uEdL1spmBpGKwSNqwMf2KxibgZGsbBfnPg9FMVIswYXCW9ScUi0nCXV5fP5/KHBw932xkEFAF+W+e2HUBI=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:mime-version:content-type:x-google-sender-auth; b=OdyL8oeKdLqyY7RAqg1rU8bm9341KVB5dhsusu6IBJa8y+QIxpApinl4fB/fpf3EPVy3KbEKCZiQJU/oVZhkxTiInZKJBAYt2MNGosu19nddCmYIZ65e9IWKyVprPsRLcpBdlf9TS0yN4/bFIZAonkn0fIXV9msAhW4kcQj4CsE=
- Sender: subbarao2z2@gmail.com
FYI
On 4/15/07, Brandon Mechtley <bmechtley@asu.edu> wrote:
Prof. Rao,
I was working through the homework, and a question popped into my head:
Perhaps
it is totally irrelevant, but is there any particular reason that the
XQuery syntax itself doesn't leverage the structure of XML? With some
clever use of oid's, I have a feeling queries could be just expressive
without requiring a non-XML grammar. Maybe that's where XML Schema
comes into play, though . . .
no--XQuery is allowed to have XML syntax, and there is a W3C working group recommendation standard called XqueryX for this:
http://www.w3.org/TR/xqueryx
Here is an excerpt from the introduction that is self-explanatory:
==========
The [XML Query 1.0
Requirements] states that "The XML Query Language MAY have more
than one syntax binding. One query language syntax MUST be
convenient for humans to read and write. One query language syntax
MUST be expressed in XML in a way that reflects the underlying
structure of the query."
XQueryX is an XML representation of an XQuery. It was created by
mapping the productions of the XQuery grammar into XML productions.
The result is not particularly convenient for humans to read and
write, but it is easy for programs to parse, and because XQueryX is
represented in XML, standard XML tools can be used to create,
interpret, or modify queries.
============
Notice the part about human readability of current Xquery syntax. This "certification" was no doubt given by geeks who think SQL is more readable than English ;-)
rao