Commit 62db9925 authored by Administrator's avatar Administrator

Fixes column nullability in MySQL scripts

Some columns of the MySQL database created by the scripts in the "db"
directory where incorrectly set as nullable. This commit fixes this
error and sets them as non nullable columns.
parent e0a21f1e
......@@ -2,14 +2,14 @@ CREATE DATABASE `daaexample`;
CREATE TABLE `daaexample`.`people` (
`id` int NOT NULL AUTO_INCREMENT,
`name` varchar(50) DEFAULT NULL,
`surname` varchar(100) DEFAULT NULL,
`name` varchar(50) NOT NULL,
`surname` varchar(100) NOT NULL,
PRIMARY KEY (`id`)
);
CREATE TABLE `daaexample`.`users` (
`login` varchar(100) NOT NULL,
`password` varchar(64) DEFAULT NULL,
`password` varchar(64) NOT NULL,
PRIMARY KEY (`login`)
);
......
......@@ -2,15 +2,15 @@ CREATE DATABASE `daaexample`;
CREATE TABLE `daaexample`.`people` (
`id` int NOT NULL AUTO_INCREMENT,
`name` varchar(50) DEFAULT NULL,
`surname` varchar(100) DEFAULT NULL,
`name` varchar(50) NOT NULL,
`surname` varchar(100) NOT NULL,
PRIMARY KEY (`id`)
);
CREATE TABLE `daaexample`.`users` (
`login` varchar(100) NOT NULL,
`password` varchar(64) DEFAULT NULL,
`password` varchar(64) NOT NULL,
PRIMARY KEY (`login`)
);
GRANT ALL ON `daaexample`.* TO 'daa'@'localhost' IDENTIFIED BY 'daa';
\ No newline at end of file
GRANT ALL ON `daaexample`.* TO 'daa'@'localhost' IDENTIFIED BY 'daa';
Markdown is supported
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