Uploaded image for project: 'Hibernate ORM'
  1. Hibernate ORM
  2. HHH-8478

AttributeConverters need to be applied to JPQL and Criteria queries

    Details

    • Last commented by a user?:
      true

      Description

      From section 3.8 of the JPA spec:

      The persistence provider must apply any conversion methods to instances of attribute values in path expressions used within Java Persistence query language queries or criteria queries (such as in comparisons, bulk updates, etc.) before sending them to the database for the query execution. When such converted attributes are used in comparison operations with literals or parameters, the value of the literal or parameter to which they are compared must also be converted.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              steve Steve Ebersole added a comment -

              In standalone TCK see com/sun/ts/tests/jpa/core/convert/Client.java#convert3Test_from_standalone

              Show
              steve Steve Ebersole added a comment - In standalone TCK see com/sun/ts/tests/jpa/core/convert/Client.java#convert3Test_from_standalone
              Hide
              steve Steve Ebersole added a comment -

              In the parameter case, we should already be covered since the Type will be used to bind the parameter value and that Type has the AttributeConverter encoded into it.

              In the literal case, we have 2 options. First, we could convert it to a parameter or we could convert the literal value "in place".

              Show
              steve Steve Ebersole added a comment - In the parameter case, we should already be covered since the Type will be used to bind the parameter value and that Type has the AttributeConverter encoded into it. In the literal case, we have 2 options. First, we could convert it to a parameter or we could convert the literal value "in place".

                People

                • Assignee:
                  steve Steve Ebersole
                  Reporter:
                  steve Steve Ebersole
                  Participants:
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - Not Specified
                    Not Specified
                    Logged:
                    Time Spent - 4h 55m
                    4h 55m

                      Development