forked from Internshala-Online-Trainings/Web-Development
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c8747f8
commit 73f9457
Showing
1 changed file
with
2 additions
and
4 deletions.
There are no files selected for viewing
6 changes: 2 additions & 4 deletions
6
Module 3 - SQL/Topic 06 - Foreign Key & Truncate/Foreign Key.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
The queries used in the lesson. | ||
|
||
CREATE table products query; | ||
CREATE table users_products query; | ||
CREATE TABLE ecommerce.products(`id` INT(11) AUTO_INCREMENT PRIMARY KEY, `name` VARCHAR(30), `category` enum('book','stationery','other')) | ||
CREATE TABLE ecommerce.users_products(`id` INT(11) AUTO_INCREMENT PRIMARY KEY, `user_id` INT(11), `products_id` INT(11)) | ||
CREATE TABLE ecommerce.products(`id` INT(11) AUTO_INCREMENT PRIMARY KEY, `name` VARCHAR(30), `category` enum('book','stationery','other')); | ||
CREATE TABLE ecommerce.users_products(`id` INT(11) AUTO_INCREMENT PRIMARY KEY, `user_id` INT(11), `products_id` INT(11)); |