jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Müller <thomas.muel...@day.com>
Subject Re: BindVariable in JCR-SQL2 CONTAINS
Date Mon, 02 Nov 2009 15:04:13 GMT
Hi,

I'm not sure, but it looks like a bug in Jackrabbit. The statement
seems to be parsed correctly, but extracting the bind variables
doesn't pick it up. Could you file a Jira bug report please? Just copy
& paste the example code below, that's enough to reproduce the issue.

Regards,
Thomas


On Mon, Nov 2, 2009 at 3:28 PM, Philipp Bunge <buge@crimson.ch> wrote:
> Hi
>
> I'm trying to use the following FullTextSearch query in Jackrabbit 2.0 beta1:
> Query query = qm.createQuery("SELECT * FROM [my:document] AS document
> WHERE CONTAINS(document.original, $x)", Query.JCR_SQL2);
>
> But the following fails with a "java.lang.IllegalArgumentException:
> not a valid variable in this query:"
> query.bindVariable("x", vf.createValue("moo"));
>
> In fact, query.getBindVariableNames() returns an empty array.
>
> Did I miss something?
>
> Thanks in advance,
> Philipp
>

Mime
View raw message