subject

Below is an ER model for some toy database.
(a) Implement this model in workbench and use your model to create the database.
(b) Write a stored procedure that inserts 3 rows of data into any one of these three tables. Your stored procedure should have condition handling capability for the following issues (i) insertion of a data record with a null value for the primary key, (ii) insertion of a record which duplicates a primary key that is already in the database. Feel free to use either a CONTINUE or EXIT handler for this.
(c) Consider the scenario where a realtor wants to see the viewing details (i. e., property number, view date) and property details (street, city, type, rooms, rent) for each property. For some reason you want this user to only ever see these details and to NEVER see the full details of the 2 underlying tables. You have decided to use a view for this - i. e., to give the user access to a view that exposes these details while denying this same user access to the underlying tables. Create a view that presents this information (Don't mind about the user access privileges configurations. Simply create this view).
(d) Create a trigger that enters a record into some log table whenever a client is deleted from the client table. The log table should contain two fields: the clientNo, and, date of deletion.
(e) Briefly discuss use-case scenarios in which one might use, (i) transactions, (ii) triggers, (iii) stored functions
DELIVERABLES:
A document that includes well labelled screenshots of your ER model in workbench, database, and images of all your results (e. g., when you run the stored procedure in (b), include screen shots to show the results for relevant use-cases that prove your procedure works as needed). Submit well labelled code for each of the tasks above (Any special instructions on how I can run your code must be included).

Client
clientNo {PK}
Name
IName
telNo
prefType
maxRent
↓ 1..1
Requests
↓ 0..*
Viewing
clientNo {PK, FK}
property No {PK, FK}
view Date
comment
↑ 0..*
Takes
↑ 1..1
Property For Rent
property No {PK}
Street
city
postcode
type
rooms
rent
ownerNo {FK}
staffNo
branchNo {FK}

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 23:30
Jaina and tomas are being considered as new tenants in an apartment. the landlord looks at their creditworthiness because he wants to be sure his new tenant pays the rent on time and in full. the table below summarizes the information that was on their applications. application information questions jaina tomas how many years have you had your job? 5 2 what is your monthly salary? $1,850 $2,500 how many credit cards do you have? 4 1 how much debt do you have? $13,000 $7,000 how many times were you late with payments on credit cards in the past year? 5 1 who will the landlord decide to be more creditworthy and why? tomas because the ratio of his debt to income is less. jaina because she has had her job longer, which makes her look more stable. jaina because she has more credit cards available to her. tomas because he makes more money per month.
Answers: 2
question
Computers and Technology, 23.06.2019 02:30
Rafael needs to add a title row to a table that he has inserted in word. what should he do? use the alignment options. use the merge and center option for all the cells in the top row. use the merge and center option on the first two cells in the top row. none of the above
Answers: 3
question
Computers and Technology, 23.06.2019 22:50
An environmental protection agency study of 12 automobiles revealed a correlation of 0.47 between engine size and emissions. at 0.01 significance level, can we conclude that there is a positive association between the variables? what is the p value? interpret.
Answers: 2
question
Computers and Technology, 24.06.2019 15:40
In the above figure, what type of cylinder arrangement is shown in the figure above? a. l-type b. v-type c. in-line d. horizontal pls make sure its right if its rong im grounded for 3months
Answers: 1
You know the right answer?
Below is an ER model for some toy database.
(a) Implement this model in workbench and use you...
Questions
question
Biology, 03.02.2020 08:00
question
Mathematics, 03.02.2020 08:00
question
Mathematics, 03.02.2020 08:00
question
English, 03.02.2020 08:00
Questions on the website: 13722363