【发布时间】:2019-12-21 17:17:14
【问题描述】:
我正在尝试使用 hibernate 编写 jpql 查询。我在@Repository 中有这样的查询
@Query(value = "select p from Product p inner join ProductsUser pu on p.prosuctId = pu.productId where pu.userId = :uuid")
但我得到一个例外
Caused by: java.lang.IllegalArgumentException: org.hibernate.hql.internal.ast.QuerySyntaxException: Path expected for join! [select p from com.example.api.dto.ProductDto p inner join ProductsUsersDto pu on p.prosuctId = pu.productId where pu.userId = :uuid]
【问题讨论】:
标签: java postgresql jpql