Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-6968

Clarify Query DSL error message regarding number format

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Unresolved
    • Major
    • None
    • 8.0.0.Final
    • None
    • None

    Description

      The query:

            Query query = queryFactory.from(User.class)
                  .select(property("name"), count("age"))
                  .having("age").gte(2.3)
                  .toBuilder().groupBy("name")
                  .build();
            List<Object[]> list = query.list();
      

      will result in an error:

      org.infinispan.client.hotrod.exceptions.HotRodClientException:Request for messageId=13 returned server error (status=0x85): org.hibernate.hql.ParsingException: ISPN028505: Invalid numeric literal '2.3'
      
      	at org.infinispan.client.hotrod.impl.protocol.Codec20.checkForErrorsInResponseStatus(Codec20.java:343)
      

      This is a bit confusing because it does not clearly state that an integer is expected.

      Attachments

        Activity

          People

            Unassigned Unassigned
            anistor Adrian Nistor (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: