hibernate 一下 CollectionOfElements
Map<String, String>
使用 CollectionOfElements
映射对象内部注释 A
。我希望通过加入 A
来获取 Map 的值以及某些条件下的关联集合。如果有人能对此提供更多说明,我将不胜感激。
最佳答案
假设您有Map<String, String>
对象内的属性 A
,下面的HQL可以获取Map的值。
SELECT elements(t.attributes) FROM A as t INNER JOIN t.attributes as aAttributes
WHERE CONDITION='XYZ'
关于java - Hibernate 获取 CollectionOfElements Map 的值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15231250/