-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathusers.sql
More file actions
33 lines (31 loc) · 982 Bytes
/
users.sql
File metadata and controls
33 lines (31 loc) · 982 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
use auth;
CREATE TABLE users
(
user_id VARCHAR(50) NOT NULL
PRIMARY KEY,
username VARCHAR(50) NOT NULL,
name VARCHAR(50) NULL,
email VARCHAR(200) NULL,
dob DATE NULL,
developer TINYINT(1) DEFAULT '0' NULL,
github_id INT NULL,
facebook_id BIGINT NULL,
google_id BIGINT NULL,
hashed_password VARCHAR(200) NULL,
data JSON NULL,
created DATETIME NOT NULL,
modified DATETIME NOT NULL,
CONSTRAINT users_user_id_uindex
UNIQUE (user_id),
CONSTRAINT users_email_uindex
UNIQUE (email),
CONSTRAINT users_username_uindex
UNIQUE (username),
CONSTRAINT users_github_id_uindex
UNIQUE (github_id),
CONSTRAINT users_facebook_id_uindex
UNIQUE (facebook_id),
CONSTRAINT users_google_id_uindex
UNIQUE (google_id)
)
ENGINE = InnoDB;