Uploaded by OBAID ULLAH AHMAD

MySQL Database Assignment: Hotel Database Creation

advertisement
Assignment 01:
Title:
Create a database of given requirements of MYSQL Workbench. Show
all the steps.
Step 01: Create table HOTEL with column hotelNo, hotelName, city with HotelNo as
primary key. Done that on SQL and the screenshot of the script is given below:
Step 02: Create table GUEST with column guestNo, guestName, guestAddress with
guestNo as primary key. Done that on SQL and the screenshot of the script is given below:
Step 03: Create table ROOM with columns RoomNo, HotelNo, type, price with RoomNo as
primary key. Done that on SQL and the snapshot is given below:
Step 04: Create table BOOKING with columns HotelNo, GuestNo, DateFrom, DateTo,
RoomNo and HotelNo, GuestNo and DateFrom are combined primary key. Done that on
SQL and screenshot of the script is given below:
Step 05: Populate each table with at least 3 rows by importing data from the CSV file. Done
that and the imported files are attached with the report. Snapshot of the script while
importing is given below:
Step 06: Transfer the data of at least 2 tables from DB to CSV files. Done that on SQL and
all the .csv files are attached with the report.
Download