0 Replies - 498 Views - Last Post: 07 May 2017 - 10:19 AM

#1 CrazySynthax  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 81
  • Joined: 12-June 15

javax.persistence.Entity doesn't exists

Posted 07 May 2017 - 10:19 AM

Hi,

I looked at this tutorial: https://spring.io/gu...ssing-data-jpa/

and I wrote a class with the statement:
import javax.persistence.Entity;



I don't know why, but I get an Error that "Entity" doesn't exist in javax.persistence package.

I also added the following dependencies to Maven:

<dependency>
            <groupId>javax.persistence</groupId>
            <artifactId>persistence-api</artifactId>
            <version>1.0.2</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-jpa</artifactId>
            <version>1.5.3.RELEASE</version>
        </dependency>


and it still didn't help.

By the way, I also asked this question on Stack Overflow and on Big Moose Saloon:
http://stackoverflow...nnotation-exist
http://stackoverflow...705247_43833662
https://coderanch.co...-exists#3187274

and I haven't got a satisfying answer so far.

I'll be grateful for your help.

Is This A Good Question/Topic? 0
  • +

Page 1 of 1