Created
May 31, 2021 15:23
-
-
Save shrinivdeshmukh/e6a1dc5405a3cc5e8c94033ad8b78466 to your computer and use it in GitHub Desktop.
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
tables: | |
user: | |
columns: | |
- name: user_id | |
type: integer | |
primary_key: true | |
- name: firstname | |
type: varchar | |
length: 20 | |
- name: lastname | |
type: varchar | |
length: 20 | |
- name: dob | |
type: date | |
- name: contact | |
type: numeric | |
nullable: false | |
unique: true | |
- name: address | |
type: varchar | |
length: 300 # Column length changed from 200 to 300 | |
order: | |
columns: | |
- name: order_id | |
type: integer | |
primary_key: true | |
- name: hotel_name | |
type: varchar | |
length: 100 | |
- name: order_date | |
type: date | |
- name: amount | |
type: float | |
- name: user_id | |
type: integer | |
foreign_key: user.user_id | |
# We add a new table called restaurant here | |
restaurant: | |
columns: | |
- name: restaurant_id | |
type: integer | |
primary_key: true | |
- name: restaurant_name | |
type: varchar | |
length: 50 | |
- name: address | |
type: varchar | |
length: 300 | |
- name: minimum_order_amount | |
type: float |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment