PART – 3. Introduction. Bill needs to enhance his admin

Added on - 21 Sep 2019

  • 19

    pages

  • 1403

    Words

  • 145

    Views

  • 0

    Downloads

Showing pages 1 to 4 of 19 pages
PART – 3IntroductionBill needs to enhance his administration into different rural areas also. He has enlisted moredrivers, with the desire that there will be drivers accessible in every suburb. The clients will havethe capacity to have orders that are delivered from eateries in a similar suburb. Bill has to knowwhether his suppers are being delivered on time according to his publicizing, so the databaseshould have the capacity to give data as required. Bill is satisfied with the way FF4U is creatingand needs to make some further enhancement to the idea. He has chosen to offer anadministration whereby clients will have the capacity to see the carbon impression of the foodthey order and have the capacity to pick appropriately. Bill is going to call this administration'Earth First'. Earth First dishes will give a carbon cost to the dish and an general EF rating fromgreen (best), through orange to red (the worst). This information is not available by allrestaurants, so just a few dishes will be accessible on the Earth First menu. Bill expects thatEarth First dishes will originate from any of the current type of nourishment he offers (veggielover, Halal ensured, noodle house, and so on). At the point when the order/receipt is printed forthe client, the carbon cost and Earth First evaluating will be incorporated along with the otherdelivery data.Implementation ProcessUser CreationAs according to the given scenario, user MARKERTL needs to be created first with theprivileges of SELECT, UPDATE, DELETE. The commands for creating users are as following:
SQL> Create user MARKERTL identified by admin;SQL> Grant Connect, Resource to MARKERTL;SQL> Grant Select, Insert, Update, Delete to MARKERTL;Table Creation1. CertificateSQL> Create table Certificate (CertificateID int primary key, CertificateName varchar2 (50));2. SuburbSQL> Create table Suburb (SuburbID int primary key, SuburbName varchar2 (50));
3. RestaurantSQL> Create table Restaurant (RestaurantID int primary key, RestaurantName varchar2 (50),RestaurantDetails varchar2 (250), Ethnicity varchar2 (50),Street varchar2 (250), SuburbID int references Suburb (SuburbID),State varchar2 (3), Zipcode char (4), PhoneNumber char (10),Constraint chk_state CHECK (State in ('NSW', 'QLD', 'SA', 'TAS','VIC', 'WA')),Constraint chk_zip CHECK (Zipcode BETWEEN 0000 AND 9999),Constraint chk_PHONE CHECK (PhoneNumber BETWEEN 0000000000 AND9999999999));
4. Restaurant_certificationSQL> Create table Restaurant_Certification (RestaurantID int, CertificateID int,DateCertification date, constraint pk_id primary key (RestaurantID, CertificateID),constraint fk_rest foreign key (RestaurantID) references Restaurant(RestaurantID)ON DELETE CASCADE, constraint fk_cert foreign key (CertificateID)references Certificate (CertificateID) ON DELETE CASCADE);
desklib-logo
You’re reading a preview
card-image

To View Complete Document

Become a Desklib Library Member.
Subscribe to our plans

Download This Document