0

如何使用 CreateCriteria 编写以下 SQL:

SELECT  sa_bec_matricula.*
FROM    sa_bec_matricula
        INNER JOIN sa_matricula ON sa_bec_matricula.sa_mtc_num = sa_matricula.sa_mtc_num
        INNER JOIN sa_periodo ON sa_matricula.sa_per_cod = sa_periodo.sa_per_cod
        INNER JOIN sa_tpo_beca ON sa_bec_matricula.sa_tpo_bec_cod = sa_tpo_beca.sa_tpo_bec_cod
WHERE   sa_periodo.sa_per_abi = 1
        AND sa_tpo_beca.sa_tpo_bec_gpr = 2 

附上模型。 链接文本

4

1 回答 1

0

这取决于您的模型以及它们如何映射到您的表,因为标准是根据对象的属性而不是模式中的表。

于 2011-05-18T07:07:48.397 回答