Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
0 votes
0 answers
11 views

javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not extract ResultSet

Here the error: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not extract ResultSet at org.hibernate.internal.ExceptionConverterImpl.convert(...
Kutman Salamatov's user avatar
-1 votes
1 answer
21 views

Issue with Changing @Table Annotation to "users" in JPA Entity Class Using H2 Database

I'm encountering an issue with my Java application where changing the @Table name in my entity class causes the application to fail during tests and runtime. Here are the details: Originally, my ...
quarks's user avatar
  • 34.7k
-1 votes
0 answers
11 views

Row updated in another transaction error unless there is a breakpoint on the save method

I have 2 methods that update an entity and have similar functionality, but I have inherited the codebase with little testing so don’t want to do a refactor yet. However, there is a bug in one of these ...
iamsimonsmale's user avatar
0 votes
1 answer
16 views

JPA Subquery return object and use on query multiselect

I'm have a java spring application that use a criteria query. The query has a multiselect and one of the values is a subquery that bring an complete entity. The application work on original enviroment ...
Felipe Schultz's user avatar
-2 votes
1 answer
30 views

JPA get highest value in column with where condition

I'm using a JpaRepository to access a table in my database. I defined the table through an entity. My goal is, to get the highest value in the wordNumber column. But I also have to distinguish entries ...
Fi0x's user avatar
  • 144
-2 votes
0 answers
22 views

How to set foreign key constraint order by JPA annotation? [closed]

I'm using JPA in a Spring-Boot application with JPA (jakarta.persistence Annotations). The creation of my DB schema (hbm2ddl=create) failed with an: ⚡ Foreign key constraint is incorrectly formed ...
Tobse's user avatar
  • 1,302
0 votes
0 answers
35 views

JPQL did not translated to SQL correctly when using Window Functions

Models: @Entity @Data //This is main entity public class Collection { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; private String name; @OneToMany(mappedBy = &...
SoT's user avatar
  • 1,143
-1 votes
2 answers
39 views

any scenario's to use @Transactional annotation at Repository delete method?

I am reveiewing the code for one of the senior member for the first peer review so he added @Transactional annotation at custom repository with delete method. The custom Repository delete method is ...
Anil Nivargi's user avatar
  • 1,663
-1 votes
0 answers
22 views

JPA Unit Test Error: Table not found During ALTER TABLE Execution

I am encountering an error in a simple JPA unit test where it attempts to execute an ALTER TABLE command on a table that it claims does not exist. Here is the relevant error message: INFO: Property ...
quarks's user avatar
  • 34.7k
0 votes
0 answers
31 views

Issuse with relationship mapping MapKeyEnumerated with an Entity List as values

I have this Entity @Entity public class MealPlanADay { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @JsonIgnore private Long id; //@OneToMany(cascade = CascadeType.ALL,...
Omar122's user avatar
0 votes
0 answers
24 views

Hibernate seems to ignore the dialect I specify

I'm using Olingo JPA for producing an OData API. The database I'm connecting to doesn't support the 'LOCATE' function; instead it implements 'POSITION'. This seems to be true of a few databases: ...
Person's user avatar
  • 1
0 votes
1 answer
64 views

IntelliJ IDE Cannot Find javax.annotation.processing.Generated Symbol While mvn test Works Correctly

I am having a problem with my project configuration and running the program and unit test. When running with mvn test the JUnit test executes propertly, but when executing from within the IntelliJ IDE,...
quarks's user avatar
  • 34.7k
-1 votes
0 answers
165 views

java: cannot find symbol - symbol: class Generated location: package javax.annotation.processing during build

What are the possible errors that are causing this: /home/api/target/generated-sources/annotations/org/example/core/user/model/User_.java:3:35 java: cannot find symbol symbol: class Generated ...
quarks's user avatar
  • 34.7k
-1 votes
1 answer
47 views

Why does VsCode generate classes with both jakarta.data.metamodel and jakarta.persistence.metamodel?

For some time now, I've had a problem in VsCode where I end up with duplicate generated sources. For example, let's take the SiteEntity entity. In /target/generated-sources/annotations/com/.../sites, ...
Fred Nobre's user avatar
0 votes
0 answers
29 views

Hibernate generating N(N+1) Updates for each Insert

On Hibernate 6.4.4 and 6.4.9, I am observing the following odd behavior. In a loop, I am doing the following: for (loop control) { SomeObject object = new SomeObject(contents); repository....
IVR Avenger's user avatar
  • 15.4k

15 30 50 per page
1
2 3 4 5
2119