From c0b6681ebcf13689c8245c039944f88d30278145 Mon Sep 17 00:00:00 2001 From: GitHub Gen Changes <> Date: Tue, 10 Sep 2024 13:10:40 +0000 Subject: [PATCH] Removed 'posts' table entirely. --- dirs/ecommerce/migrations/20240910131040.sql | 2 ++ dirs/ecommerce/migrations/atlas.sum | 3 ++- dirs/ecommerce/schema.sql | 13 +------------ 3 files changed, 5 insertions(+), 13 deletions(-) create mode 100644 dirs/ecommerce/migrations/20240910131040.sql diff --git a/dirs/ecommerce/migrations/20240910131040.sql b/dirs/ecommerce/migrations/20240910131040.sql new file mode 100644 index 0000000..18bf63b --- /dev/null +++ b/dirs/ecommerce/migrations/20240910131040.sql @@ -0,0 +1,2 @@ +-- Drop "posts" table +DROP TABLE `posts`; diff --git a/dirs/ecommerce/migrations/atlas.sum b/dirs/ecommerce/migrations/atlas.sum index 4c5acbd..ad75ae5 100644 --- a/dirs/ecommerce/migrations/atlas.sum +++ b/dirs/ecommerce/migrations/atlas.sum @@ -1,4 +1,4 @@ -h1:55qUC1rpNkBuvU+91gLBMyG7VZXdXEn8DgVLkEbYkfM= +h1:4sqIaHYHb8OownAoKW5FV5jS7H/eyb14yMK3cH9U3sU= 20230316085611.sql h1:br6W6LPEnnsejlz/7hRm9zthwStCzjN2vZkqVPxlmvo= 20230316090502.sql h1:GfeRjkSeoCt3JVRtLQNa/r50lRfpAPXS7AqTU2ZNFgY= 20230531091333_products_categories.sql h1:59q2M59dV5dJNv4Lyb2TAJz8V6HekgkLn9z4DoL98jA= @@ -44,3 +44,4 @@ h1:55qUC1rpNkBuvU+91gLBMyG7VZXdXEn8DgVLkEbYkfM= 20240829131016.sql h1:0zYZTAkT2bM3KovKz9e3KrmSKjwqM7qbkIHK1Yybh2c= 20240901130920.sql h1:Dq3nUz8IibffiSag7Lw7UZjTM0Dj8EZssyn5mUSqX84= 20240903131010.sql h1:GGqMn45ltGFdUkBkGu+Z1BK582+Cb3jPSv0PtZDyg80= +20240910131040.sql h1:XP5zaF4ac+sQLMZ24tAxQhA2uDttr5P8/gYS76eNVUc= diff --git a/dirs/ecommerce/schema.sql b/dirs/ecommerce/schema.sql index 62a3f10..028b693 100644 --- a/dirs/ecommerce/schema.sql +++ b/dirs/ecommerce/schema.sql @@ -118,17 +118,6 @@ CONSTRAINT `order_items_ibfk_1` FOREIGN KEY (`order_id`) REFERENCES `orders` (`i CONSTRAINT `order_items_ibfk_2` FOREIGN KEY (`product_id`) REFERENCES `products` (`id`) ON UPDATE NO ACTION ON DELETE CASCADE ) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci; --- Create 'posts' table -CREATE TABLE `posts` ( -`id` int NOT NULL, -`user_id` int NOT NULL, -`title` varchar(255) NOT NULL, -`body` text NOT NULL, -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; - -- Create 'payment_methods' table CREATE TABLE `payment_methods` ( `id` int NOT NULL, @@ -140,4 +129,4 @@ CREATE TABLE `payment_methods` ( PRIMARY KEY (`id`), INDEX `user_id` (`user_id`), CONSTRAINT `payment_methods_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION ON DELETE CASCADE -) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci; \ No newline at end of file +) CHARSET utf8mb4 COLLATE utf8mb4_0900_ai_ci;