Advertisement
Guest User

Untitled

a guest
Jun 12th, 2013
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 0.76 KB | None | 0 0
  1. | Accounts | CREATE TABLE `Accounts` (
  2.   `id` int(11) NOT NULL AUTO_INCREMENT,
  3.   `birth_day` date NOT NULL,
  4.   `first_name` varchar(255) NOT NULL,
  5.   `last_name` varchar(255) NOT NULL,
  6.   `mobile_phone` varchar(255) NOT NULL,
  7.   `password` varchar(255) NOT NULL,
  8.   PRIMARY KEY (`id`),
  9.   UNIQUE KEY `mobile_phone` (`mobile_phone`)
  10. ) ENGINE=InnoDB DEFAULT CHARSET=latin1 |
  11.  
  12. | Mails | CREATE TABLE `Mails` (
  13.   `id` int(11) NOT NULL AUTO_INCREMENT,
  14.   `name` varchar(255) NOT NULL,
  15.   `registration_date` date NOT NULL,
  16.   `user_id` int(11) NOT NULL,
  17.   PRIMARY KEY (`id`),
  18.   UNIQUE KEY `name` (`name`),
  19.   KEY `FK46AC17C61ACE59B` (`user_id`),
  20.   CONSTRAINT `FK46AC17C61ACE59B` FOREIGN KEY (`user_id`) REFERENCES `Accounts` (`id`)
  21. ) ENGINE=InnoDB DEFAULT CHARSET=latin1 |
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement