On Feb 6, 2007, at 14:27 , Harold CAPITAINE wrote:
Hi List,
I have a problem concerning JCR queries. I explain my case:
- I have added a node in the dmsEdit dialog to add a data
concerning documents.
- I have set a nodedata called "name" with the value "name of test"
- I have created a new document and filled the field "name of test"
with the value "test"
The problem is that when I create a query to find this doc in the
DMS repository, I do this query:
//*[jcr:like(@value of test ,'%test%')]
It returns no results.
Although this query works fine and returns many docs:
//*[jcr:like(@language ,'%English%')]
So I think the problem is the space in the name of the attribute.
Most certainly.
Is it a limitation of magnolia?
Certainly not. Most likely a jcr "limitation", however, I wouldn't
call that a limitation, since it's the case for probably about 99.99%
of the (query|programming) languages in computer land.
How can I solve this problem?
By not using spaces in your attribute names ?
Or quoting them, maybe? Check the jcr spec - but I would just advise
using spaces in attribute names in general ...
Also, check MAGNOLIA-1338. At the moment, if you're using the query
tool, not getting any result might just mean your query is invalid.
Check the logs.
cheers,
greg
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------