每次我做一個JPA項目時,Eclipse報告我的項目中有錯誤,但我不明白它爲什麼這樣做。我添加圖像和下面的錯誤:Eclipse報告我的JPA項目錯誤
Description Resource Path Location Type Column "id" cannot be resolved on table "page" Page.java /BreakpointJPA/src/no/breakpoint/domain line 14 JPA Problem
Description Resource Path Location Type Column "title" cannot be resolved on table "page" Page.java /BreakpointJPA/src/no/breakpoint/domain line 18 JPA Problem
Description Resource Path Location Type Primary key join column "id" cannot be resolved on table "page" Page.java /BreakpointJPA/src/no/breakpoint/domain line 10 JPA Problem
你能顯示你的'頁面'表的細節嗎? –
是的,我還沒有實現時間戳,所以他們不在頁面實體中的原因。 – LuckyLuke
所以我猜Eclipse是說你的實體沒有正確地反映數據庫的狀態? Eclipse如何知道你正在使用哪個數據庫?也許它沒有使用你顯示的數據庫'adesnqhp_javaee'? –