skip to Main Content

How to change for Postgresql the string value for json in jpa repository @Query using springboot

Maven pom dependency: <dependency> <groupId>org.postgresql</groupId> <artifactId>postgresql</artifactId> <scope>runtime</scope> </dependency> <!-- https://mvnrepository.com/artifact/org.json/json --> <dependency> <groupId>org.json</groupId> <artifactId>json</artifactId> <version>20230227</version> </dependency> Configuration Dialect: spring: jpa: properties: hibernate: dialect: org.hibernate.dialect.PostgreSQLDialect show-sql: 'true' hibernate: ddl-auto: update I have the following Entity: @Entity @Data @Getter @AllArgsConstructor @NoArgsConstructor @Builder…

VIEW QUESTION

Mysql – The IN operator in sql

In the nobel quiz, there is a question "Write the code which would show the year when neither a Physics or Chemistry award was given'. My code is as following: SELECT yr FROM nobel WHERE subject NOT IN ('Chemistry','Physics') The…

VIEW QUESTION
Back To Top
Search