Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Assignment 5 : QueriesSummary:Write queries on the video store database in Access. There is no rubric for this assignment. Each question isworth 1 2 .
Assignment : QueriesSummary:Write queries on the video store database in Access. There is no rubric for this assignment. Each question isworth points.SetupDownload the video store database also available from ContentResources CISD for the first part ofthe assignment. Rename the file YLNaaccdb, using your last name, eg Smithaaccdb. Execute Accessand open this file. You will probably find it helpful to look at the ERD for it in Resources CIS D Queries in AccessWrite the following queries on your video store database, saving each query with the indicated name Q Qetc. Each query is worth points. Be sure to write each query exactly as specified and show only thecolumns requested.Q: Produce a list of all movies in the video store, displaying the title and year only Sort by year with thenewest movies first.Q: Select customer accounts which have a credit card on file and have a deposit amount greater than Display the customer account id and date enrolled only and sort by date enrolled. Hint: This query shouldreturn rows of data.Q: Show a list of employee name given and family and hire dates. Sort by family name. Hint: You willneed to join the EMPLOYEE and PERSON tables.Q: List in alphabetical order the languages that the movie Das Boot is available in The query result shouldhave only one column named "Das Boot Languages" and three rows giving the names of the languages.The video store ERD will be helpful to figure out what tables are needed, even though you are projectingonly one column. I.e the result should look like this:Q: Produce a list of movies that are currently rented out ie the returned date in the MOVIERENTALtable is null Show the movie title, copy number, and customer account id for the rental. Sort by movie titleand then copy number. Hints: You may need to join tables together for this query. This query shouldreturn rows of data.Q: Write a query that shows what the movie rental fees for all rentals in the database would be if reducedby eg a $ fee would become $ Use the MOVIERENTAL table and display the movie idCISDAdocx Page of transaction id and the rental fee reduced by Name this last column "Reduced Rental Fee". Round to decimal places using the Round function.Q: Use aggregates on the 'Total: line use Totals button to show the minimum, maximum, and averageamount paid in sales tax on a customer transaction. The result should have one row that looks like thisname columns appropriately:Q: Show a list of movies in the database along with the number of languages associated with each movie.Display the movie title column name: "Title" and the number of languages column name: "Number ofLanguages" Sort by the count descending. Hint: You will need to use an aggregate for this,specifically, Count, and you can count the column LANGUAGECODE in the MOVIELANGUAGEtable.SubmissionUpload your database file containing Q through Q YLNaaccdb as usual to the assignment folder.Script to copyCREATE TABLE EMPLOYEE EMPNUM varcharEMPLNAME varcharEMPFNAME varcharEMPINITIAL varcharEMPHIREDATE datetime,JOBCODE varcharEMPYEARS int;INSERT INTO EMPLOYEE VALUES'News','John',G;INSERT INTO EMPLOYEE VALUES'Senior','David',H;INSERT INTO EMPLOYEE VALUES'Arbough','June',E;INSERT INTO EMPLOYEE VALUES'Ramoras','Anne',K;INSERT INTO EMPLOYEE VALUES'Johnson','Alice',K;INSERT INTO EMPLOYEE VALUES'Smithfield','William',;INSERT INTO EMPLOYEE VALUES'Alonzo','Maria',D;INSERT INTO EMPLOYEE VALUES'Washington','Ralph',B;INSERT INTO EMPLOYEE VALUES'Smith','Larry',W;INSERT INTO EMPLOYEE VALUES'Olenko','Gerald',A;INSERT INTO EMPLOYEE VALUES'Wabash','Geoff',B;INSERT INTO EMPLOYEE VALUES'Smithson','Darlene',M;INSERT INTO EMPLOYEE VALUES'Joenbrood','Delbert',K;INSERT INTO EMPLOYEE VALUES'Jones','Annelise',;INSERT INTO EMPLOYEE VALUES'Bawangi','Travis',B;INSERT INTO EMPLOYEE VALUES'Pratt','Gerald',L;INSERT INTO EMPLOYEE VALUES'Williamson','Angie',H;INSERT INTO EMPLOYEE VALUES'Frommer','James',J;CREATE TABLE JOB JOBCODE varcharJOBDESCRIPTION varcharJOBCHGHOUR floatJOBLASTUPDATE datetime;INSERT INTO JOB VALUES'Programmer',;INSERT INTO JOB VALUES'Systems Analyst',;INSERT INTO JOB VALUES'Database Designer',;INSERT INTO JOB VALUES'Electrical Engineer',;INSERT INTO JOB VALUES'Mechanical Engineer',;INSERT INTO JOB VALUES'Civil Engineer',;INSERT INTO JOB VALUES'Clerical Support',;CISDAdocx Page of INSERT INTO JOB VALUESDSS Analyst',;INSERT INTO JOB VALUES'Applications Designer',;INSERT INTO JOB VALUES'Bio Technician',;INSERT INTO JOB VALUES'General Support',;
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