Error after migration from Hibernate 5.6.15 to Hibernate 6.2.1.Final: Unable to determine bean info from class [jakarta.persistence.Tuple]

Description

After migration from “Hibernate 5.6.15” to “Hibernate 6.2.1.Final” we started receiving errors while fetching items from the database using criteriaBuilder.createQuery(Tuple.class) (Tuple is imported from jakarta):

-”org.hibernate.internal.util.beans.BeanIntrospectionException: Unable to determine bean info from class [jakarta.persistence.Tuple]”

-”java.lang.object not superclass of jakarta.persistence.tuple”

The error persists in all 6.x.x. versions.

Activity

Show:

Daniel Novo October 26, 2023 at 11:08 AM

Thanks for your quick response. It’s fixed.

Marco Belladelli October 26, 2023 at 10:24 AM

Hi , you don’t need to use construct when creating a Tuple typed query. You should instead use the CriteriaBuilder#multiselect method instead of select, and just pass the different attributes you want to select.

Here’s how your query would look:

Daniel Novo October 26, 2023 at 10:15 AM

Hi,

I stumble on this issue. Added an example

Can you please reopen this issue? Thanks

Automation for Jira August 3, 2023 at 5:01 AM

This issue is being closed by automation because a test case was requested, but not provided.

Marco Belladelli April 28, 2023 at 1:28 PM

We need more information to help with your problem. It would be nice if you could provide a simple reproducer for the error you’re encountering, you can start from our test case templates.

Incomplete

Details

Assignee

Reporter

Worked in

Components

Affects versions

Priority

Created April 28, 2023 at 1:02 PM
Updated October 26, 2023 at 11:08 AM
Resolved August 3, 2023 at 5:01 AM