XML query language

Paul Prescod paul at prescod.net
Wed Mar 31 20:07:19 BST 1999

Mark Birbeck wrote:
> Paul Prescod wrote:
> > And that model has a concept of nodelist -- this is the most
> > appropriate return value for query results.
> What do you mean by nodelist? Does it take into account that result
> nodes may be returned from different parts of the tree, or even at
> different depths? 

Sure. A node list is a list of nodes. No more, no less.

> It would be quite inefficient to encode the entire
> path of each node and just list each result.

Query languages have nothing to do with encodings. That's the point I'm
trying to make. If you want to make a "query results encoding language" --
great. Ideally it would work with the results returned by *any query
language*. But you *must* be able to use the query language without the
query encoding language -- i.e. in the middle of a Python or Java program,
in a stylesheet, in a GUI.

> In fact, we love it so much that we use it for everything that is
> returned from our server! Even one article is returned as a fragment.
> Interested to know what people think of this approach.

It looks good for the special case where the query results must be
communicated between processes. It isn't useful for the other cases. In
the middle of my Python or Java program I'm certainly not going to do a
query and then re-parse the results. The results should be returned as a
list of PyObject or java.lang.object references.

Summary: If the query language is going to have maximum usefulness it must
not specify that the results must be encoded in any special syntax or that
they must be encoded at all. Encoding results is another important but
separate issue (just as it is SQL).

 Paul Prescod  - ISOGEN Consulting Engineer speaking for only himself

"Perpetually obsolescing and thus losing all data and programs every 10
years (the current pattern) is no way to run an information economy or
a civilization." - Stewart Brand, founder of the Whole Earth Catalog

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)

More information about the Xml-dev mailing list