1) I try the simple quote but it doesn't fix it. I still have the problem.
2) To get the reference to the query manager, I do:
QueryManager queryManager =
ContentRepository.getHierarchyManager("dms").getQueryManager();
and then use the code in my preceding post.
PS: the queryString is more like that:
String query= "//*[(@creationDate<xs:dateTime(\"2006-10-18T00:00:00\"))]";
the "\" avoid to close the string
CAPITAINE Harold
Nicolas Modrzyk a écrit :
not sure but the date should be in between single quotes:
xs:dateTime('2006-10-18T00:00:00')
if the above doesn't fix it, how do you get the reference to the query
manager ?
Niko,
On Oct 18, 2006, at 5:56 PM, Harold CAPITAINE wrote:
I'm not sure that I really well expressed my request.
I'm doing a jcr request so I do:
String query= "//*[(@creationDate<xs:dateTime("2006-10-18T00:00:00"))]";
...
Query query = manager.createQuery(queryStr, "xpath");
QueryResult result = query.execute();
And I get the error:
javax.jcr.query.InvalidQueryException: Unable to parse string literal
for xs:dateTime: 2006-10-18T00:00:00
So I don't know if I really use it in the right way, but would you
have an example to illustrate it or could you correct mine.
Thanks,
CAPITAINE Harold
Nicolas Modrzyk a écrit :
Hey Harold,
I got that answer from the jackrabbit list before:
xs:dateTime('value')
and is is working.
Regards,
Niko
PS: please use the user list next time ...
Hi list,
Would anyone know how to get a node thanks to a jcr request on the
date of the node?
I think that it seems like this:
//[EMAIL PROTECTED]'%value%']
Actually this request doesn't work because I should use a parameter
beginning by "jcr:xxxx" but I don't know which?
Waiting for your ideas.
Thanks,
CAPITAINE Harold
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------