[infinispan-issues] [JBoss JIRA] (ISPN-8733) "between" query DSL does not support named parameters
Alex Furmanski (JIRA)
issues at jboss.org
Tue Jan 30 06:17:00 EST 2018
Alex Furmanski created ISPN-8733:
------------------------------------
Summary: "between" query DSL does not support named parameters
Key: ISPN-8733
URL: https://issues.jboss.org/browse/ISPN-8733
Project: Infinispan
Issue Type: Bug
Components: Remote Querying
Reporter: Alex Furmanski
When trying to use {{between}} in a query with named parameters I receive an exception.
{code:java}
Query q = Search.getQueryFactory(remoteCache).from("myClass")
.having("myField").between(Expression.param("from"), Expression.param("to"))
.build();
{code}
Exception received:
{noformat}
java.lang.IllegalArgumentException: ISPN014802: 'from' must be an instance of java.lang.Comparable
at org.infinispan.query.dsl.impl.ValueRange.<init>(ValueRange.java:28)
at org.infinispan.query.dsl.impl.AttributeCondition.between(AttributeCondition.java:144)
at org.infinispan.query.dsl.impl.AttributeCondition.between(AttributeCondition.java:16)
at com.example.CacheTest.query
{noformat}
This appears to affect all versions (i.e.: the thrown exception is present in https://github.com/infinispan/infinispan/blob/master/query-dsl/src/main/java/org/infinispan/query/dsl/impl/ValueRange.java)
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the infinispan-issues
mailing list