· 7 years ago · Nov 21, 2018, 02:00 PM
1create table if not exists `profiles`(
2`id` int NOT NULL,
3`uid` int NOT NULL,
4`updated` datetime NOT NULL,
5`location` varchar(128),
6`messengers` varchar(256),
7`pdata` text(2048),
8INDEX(id),
9INDEX(uid),
10PRIMARY KEY(id),
11FOREIGN KEY(uid)
12REFERENCES users(id)
13ON UPDATE CASCADE ON DELETE CASCADE
14) ENGINE=INNODB;