Robert Sanderson wrote:
> On Wed, 3 Nov 2004, Adam Dickmeiss wrote:
>> [email protected]:~/proj/yaz/test$ ../util/cql2xcql
>>> dc="first" >dc="second" dc.title=x
> My toXCQL() rewriter simply turns the query as sent into XCQL. For
> example, if I send a query with SRU and want to reconstruct it later from
> the echoed XCQL, then it's not going to be the same if you've resolved all
> of the indexes.
The query is not going to be the same byte-by-byte when you convert
"back". The samentics, however are the same. Unresolved prefixes, btw,
are kept as is.
> If my XCQL->CQL stylesheet assumes that because it will never send a
> prefix, it will never get one back, it's going to die on your response.
> Secondly it will probably generate bizarre CQL like:
> >"second" dc.title any fish
Wouldn't that be?
>"second" title any fish
which is not bizarre. In fact it states more explicitly what the query
_means_ . A client does not have to look into ZeeRex to determine
prefixes names. And the query, in principle should be easy to fire
against many databases.
dc.title any fish
does not tell. A client would have to inspect the ZeeRex record (for
each database) to determine what dc means.
> Secondly, it requires knowledge of the context in which the query is sent
> to resolve the indexes. If I send:
> foo.title = "duck"
> And my ZeeRex has a mapping of foo to Dublin Core, then foo should be a
> perfectly valid prefix to use. But a stand alone parser will complain
> that foo doesn't resolve to anything, because it lacks that context.
Either the backend knows "foo" or your CQL parser is told about it.
Semantics are the same. For example, if Zeerex defines default prefix
dc, default prefix being dc as well, the parser would be "configured"
with thoses prefixes in a SRW server. It is like adding a prefix to a CQL:
> 'info:srw/../1/dc-v1.1' dc='info:srw/.../1/dc-v1.1' q
> ,'/:. 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