6.7 LAB - Create Vehicle and EventVehicle tables The California DMV's completed table diagram is presented in the zyBook. The following is a portion of the table di Vehicle VehicleID TypeCode R YearNumber R MakeCode R ModelName R PlateID R VehicleEvent StateCode R -restrict- • VehicleID RegistrationDate -restrict- • EventNumber Event •EventNumber EventDateTime R LocationDesc R set null Officer • OfficerNumber BadgeNumber R DepartmentCode R FullName R RankCode ReportDesc EventCode R CauseEventNumber restrict ReportOfficerNumber R The SQL below creates the Officer and Event tables. Create the vehicle and VehicleEvent tables with columns matching the table diagram above and with the appropriate keys and constraints. Some additional notes: All "ID", "Number", and "Code" columns should use unsigned INT data types. • All primary keys should auto-increment. • The vehicle's model name should be limited to 20 characters. 22315042387429-3y
6.7 LAB - Create Vehicle and EventVehicle tables The California DMV's completed table diagram is presented in the zyBook. The following is a portion of the table di Vehicle VehicleID TypeCode R YearNumber R MakeCode R ModelName R PlateID R VehicleEvent StateCode R -restrict- • VehicleID RegistrationDate -restrict- • EventNumber Event •EventNumber EventDateTime R LocationDesc R set null Officer • OfficerNumber BadgeNumber R DepartmentCode R FullName R RankCode ReportDesc EventCode R CauseEventNumber restrict ReportOfficerNumber R The SQL below creates the Officer and Event tables. Create the vehicle and VehicleEvent tables with columns matching the table diagram above and with the appropriate keys and constraints. Some additional notes: All "ID", "Number", and "Code" columns should use unsigned INT data types. • All primary keys should auto-increment. • The vehicle's model name should be limited to 20 characters. 22315042387429-3y
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question

Transcribed Image Text:6.7 LAB - Create Vehicle and EventVehicle tables
The California DMV's completed table diagram is presented in the zyBook. The following is a portion of the table di
Vehicle
VehicleID
TypeCode R
YearNumber R
MakeCode R
ModelName R
PlateID R
VehicleEvent
StateCode R
-restrict-
• VehicleID
RegistrationDate
-restrict-
• EventNumber

Transcribed Image Text:Event
•EventNumber
EventDateTime R
LocationDesc R
set null
Officer
• OfficerNumber
BadgeNumber R
DepartmentCode R
FullName R
RankCode
ReportDesc
EventCode R
CauseEventNumber
restrict ReportOfficerNumber R
The SQL below creates the Officer and Event tables.
Create the vehicle and VehicleEvent tables with columns matching the table diagram above and with the appropriate keys and constraints.
Some additional notes:
All "ID", "Number", and "Code" columns should use unsigned INT data types.
• All primary keys should auto-increment.
• The vehicle's model name should be limited to 20 characters.
22315042387429-3y
AI-Generated Solution
Unlock instant AI solutions
Tap the button
to generate a solution
Recommended textbooks for you

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON

Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning

Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education