首页 > Web开发 > 详细

Hibernate(六):一对多

时间:2017-05-24 14:24:01      阅读:337      评论:0      收藏:0      [点我收藏+]

Hibernate:

create table CUSTOMER (
CUSTOMER_ID integer not null auto_increment,
CUSTOMER_NAME varchar(255),
primary key (CUSTOMER_ID)
) engine=InnoDB
Hibernate:

create table ORDERS (
ORDER_ID integer not null,
ORDER_NAME varchar(255),
CUSTOMER_ID integer,
primary key (ORDER_ID)
) engine=InnoDB
Hibernate:

alter table ORDERS
add constraint FKkdbly1ij6f4kqh378kfne6ilx
foreign key (CUSTOMER_ID)
references CUSTOMER (CUSTOMER_ID)

Hibernate(六):一对多

原文:http://www.cnblogs.com/yy3b2007com/p/6898489.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!