码迷,mamicode.com
首页 > Web开发 > 详细

Hibernate(六):一对多

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

标签:innodb   custom   arch   str   arc   ima   一对多   inno   create   

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(六):一对多

标签:innodb   custom   arch   str   arc   ima   一对多   inno   create   

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

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!