forked from sourabhagrawal/mypa
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmysql-init.txt
More file actions
27 lines (24 loc) · 822 Bytes
/
mysql-init.txt
File metadata and controls
27 lines (24 loc) · 822 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
drop database mypa;
create database mypa;
use mypa;
revoke all privileges on *.* from 'bill'@'localhost';
drop user 'bill'@'localhost';
create user 'bill'@'localhost' identified by 'clinton';
grant delete, insert, select, update on mypa.* to 'bill'@'localhost';
CREATE TABLE `notes` (
`note_id` varchar(50) NOT NULL,
`user` varchar(100) NOT NULL,
`subject` text NOT NULL,
`body` text,
`creation_epoch` bigint(20) NOT NULL,
`exec_cron` varchar(20) DEFAULT NULL,
`attachments` text,
`receipents` text,
`actions` varchar(50) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
CREATE TABLE `schedules` (
`note_id` varchar(50) NOT NULL,
`timestamp` varchar(50) DEFAULT NULL,
`user` varchar(100) NOT NULL,
UNIQUE KEY `note_id` (`note_id`,`timestamp`,`user`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1