1
0
mirror of https://github.com/chylex/Lightning-Tracker.git synced 2025-08-16 20:31:43 +02:00
Files
.github
.idea
build
dev
res
~database
IssueTable.sql
IssueWeightTable.sql
IssueWeightValues.sql
MilestoneTable.sql
ProjectMemberTable.sql
ProjectRolePermissionTable.sql
ProjectRoleTable.sql
ProjectTable.sql
ProjectUserSettingsTable.sql
SystemRolePermissionTable.sql
SystemRoleTable.sql
SystemRoleValues.sql
UserLoginTable.sql
UserTable.sql
~resources
src
tests
.gitattributes
.gitignore
LICENSE
README.md
codecept.bat
codeception.yml
composer.json
composer.lock

18 lines
637 B
SQL

CREATE TABLE IF NOT EXISTS `users` (
`id` CHAR(9) NOT NULL,
`name` VARCHAR(32) NOT NULL,
`email` VARCHAR(191) NOT NULL, # Size limit needed due to low key size limits in older versions of MySQL.
`password` VARCHAR(255) NOT NULL,
`role_id` SMALLINT DEFAULT NULL,
`date_registered` DATETIME NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `name` (`name`),
UNIQUE KEY `email` (`email`),
CONSTRAINT fk__user__role FOREIGN KEY (`role_id`)
REFERENCES `system_roles` (`id`)
ON UPDATE CASCADE
ON DELETE SET NULL
) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4
COLLATE utf8mb4_general_ci