首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > 其他数据库 >

hibernate set聚合配置 many-to-many

2012-07-04 
hibernate set集合配置 many-to-many1.user.hbm.xmlset namestationSet tableT_USER_STATION inver

hibernate set集合配置 many-to-many

1.user.hbm.xml

<set name="stationSet" table="T_USER_STATION" inverse="true" cascade="all" lazy="true"><key column="I_USER_ID" /><many-to-many column="I_STATION_ID" /></set>

?2.station.hbm.xml

<set name="userSet" table="T_USER_STATION" inverse="true" cascade="all" lazy="true"><key column="I_STATION_ID" /><many-to-many column="I_USER_ID" /></set>
?

热点排行