> Just when we are about it - an xpath expression on CQL ?? Something like
> /this/that[@attribute="xyz"]=somestuff
We can sort of already do this if the CQL parser allows for quoted,
dynamic indexes. Equally, the value could be hacked into a relation
modifier value with a magical index.
foo.magical any/foo.xpath="/this/that[@attribute='xyz']" somestuff
However it does not fit the abstract data model of SRW nor CQL, as we
cannot determine several crucial things required to process the above
query:
* Schema that the server uses internally, if any
* Schema that the XPath expression should be applied to
* Namespaces for the XPath expression
Secondly, XPath over the wire is practically never the right solution.
If you control the server, then you can define an index in a profile which
resolves to that XPath. If you don't know the data, then you can't tell
what to use in the XPath. If the data changes, your query is suddenly
inaccurate (eg going from one version of a schema to another) or if the
data is heterogeneous (MODS data and MARCXML data in the same database)
So the only situation in which it would be useful would be:
* The server only supplies one schema, or can determine which schema to
use from the XPath expression
* The records do not use namespaces
* The client knows the data and the schema
* The data is completely homogeneous
Hence there isn't an official XPath query type.
Rob
,'/:. Dr Robert Sanderson ([log in to unmask])
,'-/::::. http://www.o-r-g.org/~azaroth/
,'--/::(@)::. Dept. of Computer Science, Room 805
,'---/::::::::::. University of Liverpool
____/:::::::::::::. L5R Shop: http://www.cardsnotwords.com/
I L L U M I N A T I
|