jpa

    0熱度

    1回答

    我遇到問題。我使用JPA製作了一個動態Web項目,名爲查詢和一個Web Servlet。下面是該項目的組織: enter image description here 這裏是類: Auto.java: package it.ecipar.model; import javax.persistence.Entity; import javax.persistence.GeneratedValu

    1熱度

    2回答

    我有沒有主鍵的數據庫視圖。它有一組唯一標識視圖中的一行的列,但其中三列可以是null。我試圖創建基於這些四列的複合主鍵的實體,而是從視圖中檢索數據時出現此錯誤: The primary key read from the row ... during the execution of the query was detected to be null. Primary keys must not

    4熱度

    1回答

    假設我有兩個實體:組織和用戶。每個用戶都可以成爲許多組織的成員,並且每個組織都可以擁有許多用戶。 @Entity public class User { @ManyToMany Set<Organization> organizations; //... } @Entity public class Organization { @ManyToMa

    0熱度

    1回答

    我試圖連接到使用彈簧啓動AWS。但是我無法啓動我的應用程序。以下是錯誤消息: - [上午12:03,2017年10月19日]:錯誤創建名爲 'org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration' 豆: 不滿意的依賴通過構造函數參數0表示; 嵌套的異常是 org.springframework.be

    0熱度

    2回答

    林學春數據+ JPA,創造類似的查詢: public interface GroupRepository extends JpaRepository<Group, Integer> { @Query("SELECT g.group, sum(ball) as sum from person ... group by ...", nativeQuery=false) List<G

    1熱度

    1回答

    通讀Java Persistence Entity Operations ATM,它具有以下聲明它: JPA通過當他們序列化或當一個持久化上下文結束自動分離實體提供了這種模式的支持。 何時持久性上下文結束?它是否在每筆交易的結尾?

    0熱度

    1回答

    我們不使用hibernate專有API。 我們遵循純粹的JPA標準API。 如何設置一個布爾值作爲參數傳遞給JPQL查詢?(javax.persistenc.Query) 以下不工作 @NamedQuery(name = "Employee.getEmployeeByState", query = "select employee.id From Employee employee where e

    0熱度

    1回答

    我正在嘗試使用jersey和spring boot jpa和hibernate通過休息api查詢數據庫。 我控制器的方法: public SomeValue doSomething(String param) { MyEntity entity = myService.queryDB(param); return conv.convertEntity(entity); }

    0熱度

    2回答

    我有2個實體是這樣的: @SQLDelete(sql = "UPDATE parent_table SET deleted = true WHERE id = ?") public class Parent { private boolean deleted; @OneToMany(cascade = CascadeType.ALL) @JoinColumn(name = "parent

    0熱度

    1回答

    我需要更新我的表內部的兩列(Job此表與其他兩個表員工和工作歷史聯合)其中一個是主鍵,但我得到錯誤,如果有人可以幫幫我! package com.touati.org.model; import java.io.Serializable; import javax.persistence.*; import java.math.BigDecimal; import java.util.Li