gpt4 book ai didi

hibernate - HQL错误:子句引用了两个不同的子句元素

转载 作者:行者123 更新时间:2023-12-02 14:14:35 25 4
gpt4 key购买 nike

我正在尝试运行此查询,这将使我计数
但它确实有效

def query  = "select count(A.id) from Artifact A "+
"LEFT JOIN A.classification C on (A.id=C.artifactId) "+
"where C.id IS NULL";
def tc = Artifact.executeQuery(query);

最佳答案

这可能会有所帮助:

def query  = "select count(A.id) from Artifact A "+
"LEFT JOIN A.classification C "+
"where C.id IS NULL";
def tc = Artifact.executeQuery(query);

您无需在此处启用,因为Artifact应该已经通过映射与分类“连接”了。

关于hibernate - HQL错误:子句引用了两个不同的子句元素,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26781273/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com