Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write the following ten MySQL queries: Display the average score of all surveys in which the writer left comments. Display the transID, dateTime, and empID

Write the following ten MySQL queries:
Display the average score of all surveys in which the writer left comments.
Display the transID, dateTime, and empID of each transaction totaling over $100.00.
Display the number of each ticket type bought in 2024(in order by number bought from highest to lowest).
List the names of all employees. For each employee trained to give tours, also list the exhibits in which the employee is trained.
List the name of each exhibit that was not cleaned today.
List the name of each exhibit containing the word "King" (words beginning with "King" are also allowed).
List the names of everyone stored in the database (employees and credit card holders).
Increase the current price of all ticket types by 5%.
Create a function that creates a new ticket in the database. The parameters for the function are the ticket type and transaction number. The function returns the ticket number, which should be 1 more than the highest ticket number previously in the database.
Create a trigger that prevents the creation of a transaction with an expired credit card.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database In Depth Relational Theory For Practitioners

Authors: C.J. Date

1st Edition

0596100124, 978-0596100124

More Books

Students also viewed these Databases questions

Question

Sketch the surfaces. 16y 2 + 9z 2 = 4x 2

Answered: 1 week ago