1:n disable constraints for the n-side?

The Problem I have a 1:n relation, but the n side shouldnt rely on constraints. So i actually wanna insert a EntityPojo via its future id, when its not saved yet ( Lets ignore that its a bad practice )…

How to create hibernate request with localdate

I have a user who has an expiration date (dateTime), I need to display all users who have not expired yet. Tried different options with DATA (), or as an example – @Query (name = “SELECT u FROM …

while sending parameters to @Query function if i give like ?1 it is trying to excute like ? only

when i try send:- @Query(value = “SELECT * FROM labels where personal_ic_id=?1 and content like ‘%2%'”,nativeQuery = true) List searchByLabels(String personalIcId, String key);…

Connecting Java with a localhost, problem with my code [closed]

to make it short, the next code import java.sql.*; public class Prueba{` public static String user=”Boss”; public static String pass=”123456″; public static …

why if i make JTable take data from database delete the first row?

I’m trying to make a Table take the data where I make condition a delete from … to … , the data returns one row thinner, maybe one row deleted? my code: JScrollPane scrollPane_9 = new JScrollPane(…

Spring Boot :Deleting a blog posts shared tag only when the last post that has it is deleted

i have a dilemma trying to get a solution for this issue. I am having 2(can be any number) blog posts that share the same tag. I have a set of tags for each added post so duplicate tags are not …

Spring Data JPA @Convert throws Operations Not Allowed exception

I am using @Convert annotation to encrypt and decrypt certain columns. @Data @Entity @Table( name = “tlp_task_comment” ) public class TaskCommentModel implements Serializable { @Id @…

Data parsed correctly from server but Android recyclerview is empty

I made an online music player with PHP code server and I have no problem fetching data in JSON format. I have a problem with the Android side where no data is shown in my recyclerview although I …

JPA repository save method inserts NULL values in MySQL instead of values provided by json request

I’m new to spring. I want to add a row in MySQL database by a post request using POSTMAN via Spring boot project. I send a post request with a json body providing neccessary values for the table. but …

Java common JDBC SQL Query strategy for Unit Test using HSQLDB and runtime using MySQL

I am developing Java Vert.x 3 application. I use HSQLDB for testing with in-memory DB and MySQL 8.0.20 for runtime. When the vertx verticle is deployed, it initializes the db and tables. Since this is …