Question: ntroduction You will be writing another SQL script. The script should work with the BabyName database, so it will need the appropriate USE statement. Test
ntroduction You will be writing another SQL script. The script should work with the BabyName database, so it will need the appropriate USE statement. Test each of the SQL statements required for the below, and then put them into the script, making sure to comment each one. Include your name, zid, and section in each of the files you submit. This is a fairly large database, so it is recommended that you add LIMIT to your SQL statements when testing, to prevent a nighneverending cascade of text from needing to be downloaded. Once youve tested your queries and you are sure that they work properly, you can remove the LIMIT for submission. Your script must do each of the following: Select the BabyName database. List all of the tables that are present in the database. Show all of the names from your birth year. Each name must be shown only once. Show all of the columns and their types for each table in the database. Show a summary of how many unique names there are in each location. Show all of the years once only where your first name appears. Some peoples names may not be present in the database. If your name is one of those, then use Chad if you are male, or Stacy if you are female. If you dont feel you fit into one of those, feel free to use Pat Display the most popular male and female names from the year Show all the information available about names similar to your name or the one you adopted from above sorted in alphabetical order by name, then, within that, by count, and finally, by the year. Show how many unique names there were in the year Show the number of rows that exist in the table. Make sure the column heading on the result shows as Rows in Table. Show how many names are in the table for each sex from the year Show a table with a column called First Letter that contains one row for each letter a name starts with, and another column named Frequency that contains how many unique names begin with each of those letters. What to turn in Submit, through Blackboard, the following: The SQL script that accomplishes the above task. You can run scripts in MariaDB using the command in the client. The output yielded by having MariaDB run the script, in a text file. You can log the output using the T command in the MariaDB client. Notes on MariaDB Client The MariaDB client has a set of nonSQL commands that allow you to control its behavior. The following is an excerpt from the output of the MariaDB client when the command h help is run. Im only showing the ones relevant to this assignment. There are more commands if you want to see them, run h yourself. help h Display this help. tee T Set outfile tooutfile Append everything into given outfile. notee t Don't write into outfile. source Execute an SQL script file. Takes a file name as an argument
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
