Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A rental company has hired you to check out their apartment rental database. The database includes the following three relationships: tenant, building and lease. The

A rental company has hired you to check out their apartment rental database. The database includes the following three relationships: tenant, building and lease. The attributes and constraints of these relationships are defined as follows:

 

Relations definitions : Locataire {id: INTEGER, Nom : CHARVAR, DateNaissance: DATE, NumTelephone : k CHARVAR} Immeuble {Appartement : Primary keys and Foreign keys (undelined) and other contraints : - - Locataire (Id, Nom, DateNaissance NOT NULL, NumTelephone} Immeuble {Appartement, Adresse, Nbrpieces NOT 

The LocID and LocName attributes in the Bailrelationship refer to the Id and Name attributes in the Locataire relationship. The Bail Address attribute refers to the attribute of the same name of the Immeuble entity.


The following tables show the information on the rentals recorded in the database.

 Appartement 12 15 3 ld 1 2 Immeuble Adresse 3825 Rue Laroche 3825 Rue Laroche 2335 Avenue Marcis Nom Jean 3 lobre 1 1 2 3 Nembes Jean Marchel Jean Marchel Pascal Beauchamp Karine Beaudoin Pascal Beauchamp 15-12-1990 

Answer following questions with information above : 


Q1 : Does all relations have adequate primary keys, i.e., that use the minimum set of attributes needed to ensure uniqueness of tuples? If not, explain and correct the primary keys.

 Q2 : Are reference constraints (foreign keys) respected? Explain your answer.  

Q3 Are null values, entity constraints and domain constraints respected? Justify your answer.

Locataire {id: INTEGER, Nom : CHARVAR, DateNaissance : DATE, NumTelephone : k CHARVAR} Immeuble {Appartement : INTEGER, Adresse : CHARVAR, Nbrpieces: INTEGER, NbrToilettes: INTEGER} Bail {IdLoc: INTEGER, NomLoc :CHARVAR, Adresse: CHARVAR, Prix: INTEGER, Datedebut: DATE, DateFin: DATE} wwwww

Step by Step Solution

There are 3 Steps involved in it

Step: 1

a SELECT apartmentANumapartmentBuildingNumapartmentFloorNum FROM apartment WHERE Availableyes b SELE... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Systems Analysis And Design

Authors: Joseph Valacich, Joey George

8th Edition

0134204921, 978-0134204925

More Books

Students also viewed these Databases questions

Question

Why are descriptive statistics so important?

Answered: 1 week ago