简体   繁体   中英

javax.persistence dose not exist but installed in maven

I didn't get an answer when I googled it.

Currently, JDK is using 1.8. JPA Plugin is also installed.

I want to use Persistence, but I can't currently use it with the following error.

(but It is really questionable why importing is possible.)

As a result of Googling, many of the answers were maven refresh, etc.

This didn't work for me.

waiting for your answer.

Thank you very much!!

在此处输入图像描述

在此处输入图像描述

在此处输入图像描述

在此处输入图像描述

Make sure you're using JDK and not JRE. Enter File > Project Structure > SDKs. Also try to add this dependency from the link: https://mvnrepository.com/artifact/javax.persistence/javax.persistence-api/2.2

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM