Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema update #60

Merged
merged 1 commit into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions dirs/ecommerce/migrations/20240711130912.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
-- Modify "users" table
ALTER TABLE `users` ADD COLUMN `last_login` timestamp NULL;
3 changes: 2 additions & 1 deletion dirs/ecommerce/migrations/atlas.sum
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
h1:5Qcz9fmqnkIhJjDMlVvjZjMATmpGPVJyWvnomXe+g+w=
h1:8LeOgYv1dWVg/LAz7/Uv2sqRTcwUeEc5eTizTEVVgZE=
20230316085611.sql h1:br6W6LPEnnsejlz/7hRm9zthwStCzjN2vZkqVPxlmvo=
20230316090502.sql h1:GfeRjkSeoCt3JVRtLQNa/r50lRfpAPXS7AqTU2ZNFgY=
20230531091333_products_categories.sql h1:59q2M59dV5dJNv4Lyb2TAJz8V6HekgkLn9z4DoL98jA=
Expand All @@ -20,3 +20,4 @@ h1:5Qcz9fmqnkIhJjDMlVvjZjMATmpGPVJyWvnomXe+g+w=
20240627130821.sql h1:vCifBjrlZekBRb6g6nmulLu2AdEzvymJBnxFkgFYFj4=
20240702130812.sql h1:u9VyU0SQLuA1LotWpxsCyvEid5FMnrgatcn/P4S4F88=
20240704130806.sql h1:vUO9cakRAqDU9jNrQgE+qyWhWCkojRoWkjAtk9Z+wgY=
20240711130912.sql h1:ySpUVLDyz5QCRpeB3kaDVarV0hwqHEmwK9S5BEkG7Zo=
3 changes: 2 additions & 1 deletion dirs/ecommerce/schema.sql
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ CREATE TABLE `users` (
`updated_at` timestamp NULL ON UPDATE CURRENT_TIMESTAMP,
`date_of_birth` date NULL,
`active` bool NOT NULL DEFAULT 1,
`last_login` timestamp NULL,
PRIMARY KEY (`id`)
) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci;
-- Create "categories" table
Expand Down Expand Up @@ -114,4 +115,4 @@ CREATE TABLE `posts` (
PRIMARY KEY (`id`),
INDEX `user_id` (`user_id`),
CONSTRAINT `posts_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION ON DELETE CASCADE
) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci;
) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci;
Loading