A Guide to SQL
9th Edition
ISBN: 9781111527273
Author: Philip J. Pratt
Publisher: Course Technology Ptr
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 7, Problem 8TD
Write the commands to obtain the following information from the system catalog. Do not execute these commands unless your instructor asks you to do so.
- a. List every table that you own.
- b. List every column in the ITEM table and its associated data type.
Expert Solution & Answer
Trending nowThis is a popular solution!
Students have asked these similar questions
Task 1:The StayWell Property Management team wants a list of all property addresses combined with the name of the owners. You will need to return three columns: the first name as FIRST_NAME, the last name as LAST_NAME, and the property address as ADDRESS of the owners.
Task 4:The StayWell maintenance team wants to minimize the number of planned visits to properties. The team wants to learn all the properties that have different planned service dates. You need to return all available data in the SERVICE_REQUEST table, where requests are made for the same property with a different NEXT_SERVICE_DATE.
Task 5:The marketing team wants to celebrate the success of StayWell with a party. The team wants a table with the names of all residents and owners combined into single column named PARTICIPANT. You need to combine this information from the tables and send it back to the team.
You do not need to create a new table in the database schema.
Task 6:The StayWell marketing team wants to send mail…
Task 13: Write the command to display only tables within the system catalog that are of the type BASE TABLE. Display only the following columns: TABLE_SCHEMA, TABLE_NAME, TABLE_TYPE.
Task 2: For each invoice placed on November 15, 2021, list the invoice number along with the ID, first name, and last name of the customer for which the invoice was created.
Chapter 7 Solutions
A Guide to SQL
Ch. 7 - What is a view?Ch. 7 - Which command creates a view?Ch. 7 - Prob. 3RQCh. 7 - What happens when a user retrieves data from a...Ch. 7 - What are three advantages of using views?Ch. 7 - Which command deletes a view?Ch. 7 - Prob. 8RQCh. 7 - Which command terminates previously granted...Ch. 7 - Prob. 10RQCh. 7 - How do you create an index? How do you create a...
Ch. 7 - Prob. 12RQCh. 7 - Does the DBMS or the user make the choice of which...Ch. 7 - Describe the information the DBMS maintains in the...Ch. 7 - The CUSTOMER table contains a foreign key,...Ch. 7 - Prob. 16RQCh. 7 - Prob. 17RQCh. 7 - Prob. 18RQCh. 7 - Prob. 19RQCh. 7 - When would you usually specify primary key...Ch. 7 - Prob. 21RQCh. 7 - Prob. 22RQCh. 7 - Prob. 23RQCh. 7 - Use SQL to make the following changes to the TAL...Ch. 7 - Create a view named ITEM_ORDER. It consists of the...Ch. 7 - Create a view named ORDER_TOTAL. It consists of...Ch. 7 - Write, but do not execute, the commands to grant...Ch. 7 - Prob. 5TDCh. 7 - Perform the following tasks: a. Create an index...Ch. 7 - Delete the index named ITEM_INDEX3.Ch. 7 - Write the commands to obtain the following...Ch. 7 - Prob. 9TDCh. 7 - Prob. 10TDCh. 7 - Toys Galore currently has a credit limit of 7,500....Ch. 7 - Use SQL to make the following changes to the...Ch. 7 - Create a view named RESERVATION_CUSTOMER. It...Ch. 7 - Create a view named TRIP_INVENTORY. It consists of...Ch. 7 - Write, but do not execute, the commands to grant...Ch. 7 - Prob. 5CATCh. 7 - Create the following indexes: a. Create an index...Ch. 7 - Prob. 7CATCh. 7 - Write the commands to obtain the following...Ch. 7 - Prob. 9CATCh. 7 - Ensure that the only legal values for the TYPE...Ch. 7 - Prob. 11CATCh. 7 - Use SQL to make the following changes to the...Ch. 7 - Create a view named CONDO_OWNERS. It consists of...Ch. 7 - Create a view named CONDO_FEES. It consists of two...Ch. 7 - Write, but do not execute, the commands to grant...Ch. 7 - Prob. 5SCGCh. 7 - Prob. 6SCGCh. 7 - Delete the OWNER_INDEX 3 index from the OWNER...Ch. 7 - Write the commands to obtain the following...Ch. 7 - Prob. 9SCGCh. 7 - Ensure that the only legal values for the BDRMS...Ch. 7 - Prob. 11SCG
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
Compile and run the sample code that uses show_bytes (file show-bytes. c) on different machines to which you ha...
Computer Systems: A Programmer's Perspective (3rd Edition)
Categorize each of the following items as either hardware or software: CPU C++ compiler ALU C++ preprocessor in...
C How to Program (8th Edition)
In Exercises 1 through 22, determine the output displayed in the text box or list box by the lines of code.
Introduction to Programming Using Visual Basic (10th Edition)
(Display three messages) Write a program that displays Welcome to Java, Welcome to Computer Science, and Progra...
Introduction to Java Programming and Data Structures, Comprehensive Version (11th Edition)
In the following field declaration from the TicketMachine class private int price; does it matter which order t...
Objects First with Java: A Practical Introduction Using BlueJ (6th Edition)
The following C++ program will not compile because the lines have been mixed up. cout Success\n; cout Success...
Starting Out with C++ from Control Structures to Objects (8th Edition)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Write the commands to obtain the following information from the system catalog. Do not execute these commands unless your instructor specifically asks you to do so. a. List every column in the CONDO_UNIT table and its associated data type. b. List every table that contains a column named OWNER_NUM.arrow_forwardWEEK 9 ASSIGNMENT#3 Part I: Complete the following exercise: Create the following table with the correct columns. Call your new table: student_course (see below). Populate this table with four rows. Make sure the student id column contains values that are also in the student id column of your student table. student id course id semester year Join the student and student_course table where the student id values are the same. Join the student and student_course table where the student id values are the same and year is equal to 2020. Create a select statement that will return the length of the last name column by joining the student and student_course table where the student id values are the same and enroll month is June. Once you have completed your assignment, copy and paste the script into a Word document. Part II: Complete the following exercise: Using a subquery, select student first name where the student is in the student course table. Using a subquery, select the…arrow_forwardTask 10: List all the tables contained within the system catalog, but only display the first 10 records with a TABLE_TYPE of SYSTEM VIEW. Task 11: List all the columns contained within the system catalog, but only display the first 11 records that are in the KimTay TABLE_SCHEMA. Task 12: List all the views contained within the system catalog, but only display the first 12 records.arrow_forward
- 4. Write a SELECT statement that selects all of the columns for the catalog view that returns information about foreign keys. How many foreign keys are defined in the AP database?arrow_forwardTask 6: Find the ID, first name, and last name of each customer for which an invoice was not created on November 15, 2021. Task 7: For each invoice, list the invoice number, invoice date, item ID, description, and category for each item that makes up the invoice.arrow_forwardTask 10 Task 10: List all the tables contained within the system catalog, but only display the first 10 records with a TABLE_TYPE of SYSTEM VIEW. Results SELECT * FROM (SELECT TABLE_NAME FROM ALL_TABLES ORDER BY TABLE_NAME) WHERE ROWNUM < = 10; ERROR 1248 (42000) at line 1: Every derived table must have its own alias Task 11 Results Task 11: List all the columns contained within the system catalog, but only display the first 11 records that are in the KimTay TABLE_SCHEMA.arrow_forward
- Task 17: List the invoice number and invoice date for each invoice that was created for James Gonzalez but that does not contain an invoice line for Wild Bird Food (25lb).arrow_forwardTask 6: Find the ID, first name, and last name of each customer for which an invoice was not created on November 15, 2021. Task 13: List the invoice number and invoice date for each invoice created for the customer James Gonzalez. Task 15: List the invoice number and invoice date for each invoice that either was created for James Gonzalez or that contains an invoice line for Wild Bird Food (25lb). TEMPLATE -- Task # 6SELECT CUSTOMER.CUST_ID, FIRST_NAME, LAST_NAMEFROM _____________, _________________WHERE CUSTOMER.________________ = ______________.CUST_IDAND INVOICES.____________________ <> '2021-11-15'; -- Task # 13SELECT INVOICE_NUM, INVOICE_DATEFROM ______________WHERE ____________ IN (SELECT CUST_ID FROM CUSTOMER WHERE _____________ = _______________AND ____________ = ______________); -- Task # 15SELECT DISTINCT INVOICES.INVOICE_NUM, INVOICES.INVOICE_DATEFROM INVOICES, INVOICE_LINE, ITEM, CUSTOMERWHERE INVOICES.INVOICE_NUM = INVOICE_LINE.INVOICE_NUMAND INVOICE_LINE.ITEM_ID =…arrow_forwardCreate a set of lookup tables.arrow_forward
- Task 16: List the invoice number and invoice date for each invoice that was created for James Gonzalez and that contains an invoice line for Wild Bird Food (25lb).arrow_forwardWhat is the format of the SET clause that changes the value in a column to null in an UPDATE command?arrow_forwardThe SERVICE_REQUEST table uses the CHAR data type for the DESCRIPTION and STATUS fields. Is there an alternate data type that could be used to store the values in these fields? Justify your reason for choosing an alternate data type or for leaving the data type as CHAR.arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- A Guide to SQLComputer ScienceISBN:9781111527273Author:Philip J. PrattPublisher:Course Technology PtrNp Ms Office 365/Excel 2016 I NtermedComputer ScienceISBN:9781337508841Author:CareyPublisher:Cengage
- Database Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781305627482Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningCOMPREHENSIVE MICROSOFT OFFICE 365 EXCEComputer ScienceISBN:9780357392676Author:FREUND, StevenPublisher:CENGAGE LDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781285196145Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos CoronelPublisher:Cengage Learning
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:9781337508841
Author:Carey
Publisher:Cengage
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781305627482
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
Computer Science
ISBN:9780357392676
Author:FREUND, Steven
Publisher:CENGAGE L
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781285196145
Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:Cengage Learning
How to Design DB Tables for any Application? (The Basics); Author: Studytonight;https://www.youtube.com/watch?v=XUdNVaSikqY;License: Standard YouTube License, CC-BY
Create a Table (Introduction to Oracle SQL); Author: Database Star;https://www.youtube.com/watch?v=BiV1IrzB1sY;License: Standard Youtube License