Question
(a) Write the DDL commands needed to create a relational database for the schema for the horse racing example shown in Figure 4.8. (b) Make
(a) Write the DDL commands needed to create a relational database for the schema for the horse racing example shown in Figure 4.8.
(b) Make up data and enter records for at least five horses (name one of them "Lucky"), six people (including owners, trainers, and jockeys), and at least one race, with at least five entries.
(c)Write SQL queries for each of the following and execute them:
(i) What are the name and telephone number of the person who trained Lucky?
(ii) What was Lucky's final position in a given race?
(iii) What are the name and address of the jockey who rode the winning horse in a particular race?
Provide your responses in a DDL file (*-schema.sql) and DML file (*-data.sql).
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started