Skip to content
Snippets Groups Projects
Commit 430bb63e authored by Jauza Lathifah Annassalafi's avatar Jauza Lathifah Annassalafi
Browse files

feat: update sql

parent 4b23b7cb
No related merge requests found
...@@ -3,18 +3,13 @@ CREATE TABLE IF NOT EXISTS `logging` ( ...@@ -3,18 +3,13 @@ CREATE TABLE IF NOT EXISTS `logging` (
`description` varchar(255) NOT NULL, `description` varchar(255) NOT NULL,
`ip` varchar(128) NOT NULL, `ip` varchar(128) NOT NULL,
`endpoint` varchar(255) NOT NULL, `endpoint` varchar(255) NOT NULL,
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(), `timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (id) PRIMARY KEY (id)
) );
CREATE TABLE IF NOT EXISTS `subscription` ( CREATE TABLE IF NOT EXISTS `subscription` (
`subscriber_id` int NOT NULL, `subscriber_id` int AUTO_INCREMENT NOT NULL,
`user_id` int NOT NULL,
`status` enum('ACCEPTED','REJECTED','PENDING') NOT NULL DEFAULT 'PENDING', `status` enum('ACCEPTED','REJECTED','PENDING') NOT NULL DEFAULT 'PENDING',
PRIMARY KEY (subscriber_id) PRIMARY KEY (subscriber_id)
) );
\ No newline at end of file
INSERT INTO `logging` (`id`, `description`, `ip`, `endpoint`, `timestamp`) VALUES
('123123', 'ini testing saja','192.168.0.1','localhost','2022-11-27 21:00:00'),
('123124', 'ini testing saja','192.168.0.1','localhost','2022-11-27 22:00:00'),
('123125', 'ini testing saja','192.168.0.1','localhost','2022-11-27 23:00:00'),
('123126', 'ini testing saja','192.168.0.1','localhost','2022-11-27 01:00:00')
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment