mirror of
https://github.com/kevinveenbirkenbach/coding-challenge-online-shop.git
synced 2024-11-01 00:53:10 +01:00
Added databases draft
This commit is contained in:
parent
f938f70e78
commit
a61f5550b7
5
src/setup/database/order.sql
Normal file
5
src/setup/database/order.sql
Normal file
@ -0,0 +1,5 @@
|
||||
CREATE TABLE `test_db`.`order` (
|
||||
`id` INT NOT NULL AUTO_INCREMENT,
|
||||
`customer` INT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE INDEX `id_UNIQUE` (`id` ASC));
|
4
src/setup/database/order_product.sql
Normal file
4
src/setup/database/order_product.sql
Normal file
@ -0,0 +1,4 @@
|
||||
CREATE TABLE `test_db`.`order_product` (
|
||||
`product_id` INT NULL,
|
||||
`order_id` INT NULL);
|
||||
|
8
src/setup/database/product.sql
Normal file
8
src/setup/database/product.sql
Normal file
@ -0,0 +1,8 @@
|
||||
CREATE TABLE `test_db`.`product` (
|
||||
`id` INT NOT NULL,
|
||||
`name` VARCHAR(45) NULL,
|
||||
`color` VARCHAR(12) NULL,
|
||||
`price` INT NULL,
|
||||
`image` VARCHAR(180) NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE INDEX `id_UNIQUE` (`id` ASC));
|
9
src/setup/database/user.sql
Normal file
9
src/setup/database/user.sql
Normal file
@ -0,0 +1,9 @@
|
||||
CREATE TABLE `test_db`.`user` (
|
||||
`id` INT NOT NULL AUTO_INCREMENT,
|
||||
`name` VARCHAR(45) NULL,
|
||||
`email` VARCHAR(45) NULL,
|
||||
`hash` VARCHAR(45) NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE INDEX `id_UNIQUE` (`id` ASC),
|
||||
UNIQUE INDEX `email_UNIQUE` (`email` ASC));
|
||||
|
0
src/setup/setup.php
Normal file
0
src/setup/setup.php
Normal file
Loading…
Reference in New Issue
Block a user