Part 1: Revised ERD and Schema.

Added on -2019-09-21

| 4 pages
| 1628 words
| 918 views

Trusted by 2+ million users,
1000+ happy students everyday

Showing pages 1 to 2 of 4 pages

Part 1: Revised ERD and Schema The revised ERD is, Following changes have been made in the revised ERD. The new entity Certificate has been added. It contains the details of the certifications of the restaurants. There is a many to many relationship between Restaurant and Certificate. So, the newassociative entity, RestaurantCertification has been added to the design. The suburb entity has been added. As suburb is an important part of the database, so keeping is asan entity will help in making queries based on suburb, adding relationships with other entities andreducing the chances of errors in the database. Attributes have been added to all entities to add more information. The 3NF relational schema contains the following relations mapped from the revised ERD. CERTIFICATE ( CertificateID, CertificateName)RESTAURANT (RestaurantID, RestaurantName, RestaurantDetails, Ethnicity, Street, SuburbID, State, Zipcode, PhoneNumber)RESTAURANT_CERTICATION (RestaurantID, CertificateID, DateCertification)
SUBURB(SuburbID, SuburbName)CUSTOMER (CustomerID, CustomerFirstName, CustomerLastName, PhoneNumber, Street, SuburbID, State, Zipcode)DRIVER(DriverID, DriverFirstName, DriverLastName, Availability, SuburbID)DISH(DishID, DishName, Description, PreparationType, MainIngredients, CourseType, EFRating, CarbonCost, Price, DeliveryTime, RestaurantID)ORDER (OrderID, DriverID, CustomerID, OrderDate, OrderDeliveryTime, ActualDeliveryTime, CurrentStatus)ORDERED_DISH (OrderID, DishID)Part 2: Data Dictionary The data dictionary is, TableAttributeBrief DescriptionDatatypeand SizeRequiredor NotConstraint(s)ReferentialIntegrityRules (ifAny)CertificateCertificateIDUnique certificate code.INTYesPrimary keyCertificateNameName of certification.VARCHAR2(50)YesRestaurantRestaurantIDUnique restaurant code.INTYesPrimary keyRestaurantNameName of a restaurant.VARCHAR2(50)YesRestaurantDetailsShort description about the restaurant.VARCHAR2(250)YesEthnicityEthnicity of the restaurant. VARCHAR2(50)YesStreetStreet details.VARCHAR2(250)YesSuburbIDSuburb IDINTYesForeign key On update StateStatecodeVARCHAR2(3)Yes {NSW, QLD, SA, TAS, VIC, WA}Zipcode4 digit zipcodeCHAR(4)Yes0000-9999PhoneNumber10 digit contact number of the restaurant. CHAR(10)Yes0000000000-9999999999Restaurant_CertificationRestaurantIDRestaurant codeINTYesPrimary key and foreign keyOn update CertificateIDCertificate codeINTYesPrimary key and foreign keyOn update

Found this document preview useful?

You are reading a preview
Upload your documents to download
or
Become a Desklib member to get accesss

Students who viewed this