Java 如何在hibernate中映射联接类
我想映射类节点、单元和模块以执行此选择:Java 如何在hibernate中映射联接类,java,hibernate,mapping,Java,Hibernate,Mapping,我想映射类节点、单元和模块以执行此选择: select n.nid, n.nnm, n.nhwtype, u.unnr, u.unhwtype, u.unslot, m.mpos, m.mhwtype from node n, unit u, module m where n.nid*=u.nid and n.nid*=m.nid and u.nid*=m.nid and u.unnr*=m.unnr and n.nhwtype in (10020, 10021, 10022, 10023, 1
select n.nid, n.nnm, n.nhwtype, u.unnr, u.unhwtype, u.unslot, m.mpos, m.mhwtype from node n, unit u, module m where n.nid*=u.nid and n.nid*=m.nid and u.nid*=m.nid and u.unnr*=m.unnr and n.nhwtype in (10020, 10021, 10022, 10023, 10002, 10017, 10001) and m.mpos not between 11 and 10000
(一)节点->单元(多个)
(一)单元->模块(多个)
我试了很多次,但都没有成功。你试了什么?发布您最好的JPQL查询尝试。您可以使用本教程