Member-only story

Spring Boot JPA @Entity “invalid identifier” java.sql.SQLException Error

Bryant Jimin Son
2 min readMay 13, 2019

--

So, I was creating a RESTful service with Spring Boot + Oracle DB, and I got the following error when I visited a REST url that I put in to a @RestController

2015–08–12 11:31:27.470 ERROR 9676 — [nio-8080-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.springframework.dao.InvalidDataAccessResourceUsageException: could not extract ResultSet; SQL [n/a]; nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet] with root cause

java.sql.SQLException: ORA-00904: “CASPRODUCT0_”.”PATH_IMG_THUMB”: invalid identifier

Here is my domain class:

import javax.persistence.Column;

import javax.persistence.Entity;

import javax.persistence.GeneratedValue;

import javax.persistence.Id;

import javax.persistence.Table;

import org.springframework.data.annotation.Transient;

@Entity

@Table(name="casproduct")

public class CasProduct {</code>

@Id

@Column(name="id", unique=true, nullable=false)

@GeneratedValue

--

--

Bryant Jimin Son
Bryant Jimin Son

Written by Bryant Jimin Son

A cloud practitioner talking about technology, travels & career tips. But I will sometimes cover financial advises and some random stuffs.

No responses yet