We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, the lucene fulltext docs explains how to query a field using search_class in the form:
search_class("field:value*") = true
For instance:
SELECT FROM City WHERE SEARCH_CLASS("+name:cas* +description:beautiful") = true
So i'm wondering if is possible do the query using ":" to include the string parameter value in the params object of the query, just like:
session.query("select from OUser where name = :name", {params: { name: "admin" }})
Instead of using something like:
`SELECT FROM City WHERE SEARCH_CLASS("+name:${val1}* +description:${val2}") = true`
I tried like this 👇 ... but didn't work 😮 😞
session.query( 'select from City where search_class("+name: :val1 * +description: :val2") = true', { params: { val1: "name", val2: "beautiful" } } );
The text was updated successfully, but these errors were encountered:
Hi @alexmm11
i think they cannot work as today. the searchClass takes a string and it does not apply parameters.
So this one will be the query passed to lucene "+name: :val1 * +description: :val2"
"+name: :val1 * +description: :val2"
Let me check if we can find a way
Thanks
Sorry, something went wrong.
Probably for now the best way is to do
`SELECT FROM City WHERE SEARCH_CLASS(:query) = true`
and use only 1 param query with +name:${val1}* +description:${val2} the lucene query content
+name:${val1}* +description:${val2}
wolf4ood
No branches or pull requests
Hi, the lucene fulltext docs explains how to query a field using search_class in the form:
For instance:
So i'm wondering if is possible do the query using ":" to include the string parameter value in the params object of the query, just like:
Instead of using something like:
`SELECT FROM City WHERE SEARCH_CLASS("+name:${val1}* +description:${val2}") = true`
I tried like this 👇 ... but didn't work 😮 😞
The text was updated successfully, but these errors were encountered: