Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Create the database and tables for the database. Show all SQL statements. Include primary and foreign keys. Insert data into each table. Show select statements
- Create the database and tables for the database. Show all SQL statements. Include primary and foreign keys.
- Insert data into each table. Show select statements and display the output of each table. Note: Students name must be inserted into table as part of the data!
- Perform the SQL below:
- Query one table and use WHERE to filter the results. The SELECT clause should have a column list, not an asterisk (*). State the purpose of the query; show the query and the output.
- Get information from at least 3 tables in one statement, and provide the output using the Join operator. Use ANSI Join syntax. State the purpose of the query; show the query and the output. Add a screen shot of SS Management Studio showing the query and results.
- Get information from 2 tables in one statement, and provide the output using the Left Outer Join operator. State the purpose of the query; show the query and the output. The outer join should be designed to retrieve information from the left table that has no matches in the right table. If that is not possible for your database, explain why.
- Create a query using the IN keyword with a subquery. State the purpose of the query; show the query and the output.
- Create a query using an aggregate function (i.e., min, max, avg, sum, count) and the GROUP BY command. State the purpose of the query; show the query and the output.
- Create a query using an aggregate function (i.e., min, max, avg, sum, count) and the GROUP BY command using the HAVING clause to filter the aggregate results. State the purpose of the query; show the query and the output.
- Update one row. State the purpose of the query; show the result set for the row(s) before the update; show the query; show the row(s) after the update.
- Delete one row. State the purpose of the query; show the result set before the delete; show the query; show the result set after the delete.
Please provide 5 database tables and follow the other points, answer should be in order
Thanks
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