Answered step by step
Verified Expert Solution
Question
1 Approved Answer
' Advance challenge: Execute the CityJail_5.sql script to rebuild the CRIMINALS and CRIMES tables of the City Jail database. The statements at the beginning of
'
Advance challenge:
Execute the CityJail_5.sql script to rebuild the CRIMINALS and CRIMES tables of the City Jail database. The statements at the beginning of this script drop existing tables in your schema with the same table names NOTE The CityJail 5.sql script is not included in the data files; it's included with the solution files, so it will be provided by your instructor Review the script so that you're familiar with the table structure and constraints, and then do the following 1. Create and execute statements to perform the following DML activities. Save the changes permanently to the database a. Create a script to allow a user to add new criminals (providing prompts to the user) to the CRIMINALS table b. Add the following criminals, using the script created in the previous step. No value needs to be entered at the prompt if it should be set to the DEFAULT column value. Query the CRIMINALSS table to confirm that new rows have been added. Criminal_ID Last First Street City 1015 1016 State Zip Phone V status P status Fenter Jim Chesapeake VA23320 Saunder Bil 11 Apple Virginia A 23455 7678217443 N Rd Beach 1017 Painter Troy 77 Ship Norfolk VA 22093 7677655454 N C. Add a column named Mail flag to the CRIMINALS table. The column should be assigned a datatype of CHAR(1). d. Set the Mail flag column to a value of Y for all criminals e. Set the Mail fag column to 'N' for all criminals who don't have a street addressrecorded in the database f. Change the phone number for criminal 1016 to 7225659032. g. Remove criminal 1017 from the databaseStep 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