A Guide to SQL
9th Edition
ISBN: 9781111527273
Author: Philip J. Pratt
Publisher: Course Technology Ptr
expand_more
expand_more
format_list_bulleted
Concept explainers
Textbook Question
Chapter 7, Problem 4TD
Write, but do not execute, the commands to grant the following privileges:
- a. User Ashton must be able to retrieve data from the ITEM table.
- b. Users Kelly and Morgan must be able to add new orders and order lines.
- c. User James must be able to change the price for all items.
- d. User Danielson must be able to delete customers.
- e. All users must be able to retrieve each customer’s number, name, street, city, state, and postal code.
- f. f User Pere7 must be able to create an index on the ORDFRS table.
- g. User Washington must be able to change the structure of the ITEM table.
- h. User Grinstead must have all privileges on the ORDERS table.
Expert Solution & Answer
Trending nowThis is a popular solution!
Students have asked these similar questions
Write and execute the command to retrieve the item ID, description, invoice number, and quoted price for all invoices in the ITEM_INVOICE VIEW for items with a quoted prices that exceed $100.
I have been trying this solution and it is incorrect:
SELECT i.item_id, i.description, l.invoice_num, l.quoted_priceFROM item iINNER JOIN invoice_line l ON i.item_id = l.item_idWHERE i.item_id IN ( SELECT item_id FROM item_invoice WHERE quoted_price > 100);
Which of the following is true?a. All data in a table can be recovered if the table is dropped with the PURGE option.b. All data in a table can be recovered from the recycle bin if the table is dropped.c. All data in a table is lost if the table is dropped.d. All of the above statements are true.
Task 5: Write and execute the command to retrieve the item ID, description, invoice number, and quoted price for all invoices in the ITEM_INVOICE VIEW for items with a quoted prices that exceed $100.
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
Leap Year Detector Design a program that asks the user to enter a year, and then displays a message indicating ...
Starting Out with Programming Logic and Design (5th Edition) (What's New in Computer Science)
A magic number is _______. a. a number that is mathematically undefined b. an unexplained value that appears in...
Starting Out with Python (4th Edition)
The ____________ is always transparent.
Web Development and Design Foundations with HTML5 (9th Edition) (What's New in Computer Science)
How does a computers main memory differ from its auxiliary memory?
Java: An Introduction to Problem Solving and Programming (7th Edition)
Computers can do many different jobs because they can be_____.
Starting Out with C++: Early Objects (9th Edition)
Convert each of the following binary representations to its equivalent base ten form: a. 101010 b. 100001 c. 10...
Computer Science: An Overview (12th 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
- Which of the following is true? All data in a table can be recovered if the table is dropped with the PURGE option. All data in a table can be recovered from the recycle bin if the table is dropped. All data in a table is lost if the table is dropped. All of the above statements are true.arrow_forwardWrite, but do not execute, the commands to grant the following privileges: a. User Oliver must be able to retrieve data from the CONDO_UNIT table. b. Users Crandall and Perez must be able to add new owners and condo units to thedatabase. c. Users Johnson and Klein must be able to change the condo fee of any unit. d. All users must be able to retrieve the unit number, condo fee, and owner number forevery condo unit. e. User Klein must be able to add and delete service categories. f. User Adams must be able to create an index on the SERVICE_REQUEST table. g. Users Adams and Klein must be able to change the structure of the CONDO_UNITtable. h. User Klein must have all privileges on the LOCATION, OWNER, and CONDO_UNITtables.arrow_forwardWhich of the following is a correct statement? a. A commit is issued implicitly when a user exits SQL Developer or SQLPlus. b. A commit is issued implicitly when a DDL command is executed. c. A commit is issued automatically when a DML command is executed. d. All of the above are correct. e. Both a and b are correct. f. Both a and c are correct.arrow_forward
- Write and execute the command to retrieve the customer ID, first name, and last name of each customer in the MAJOR_CUSTOMER VIEW with a balance that exceeds the credit limit.arrow_forwardUse the "uniq -c" command to sort and summarize the total occurrences of sudo access by month and user. Submit - Screen shot of your syntax and output showing total occurrences by month and user of sudo access, for example: 112 Apr msmith 101 Mar admin What command should we use??arrow_forwardWhich of the following is a correct statement?a. If you attempt to add a record that violates a constraint for one of the table’s columns, only the valid columns for the row are added.b. A subquery nested in the VALUES clause of an INSERT INTO command can return only one value without generating an Oracle 12c error message.c. If you attempt to add a record that violates a NOT NULL constraint, a blank space is inserted automatically in the appropriate column so that Oracle 12c can complete the DML operation.d. None of the above statements is correct.arrow_forward
- 5-39. Write SQL commands for the following: Create two different forms of the INSERT command to add a student with a student ID of 65798 and last name Lopez to the STUDENT table. Now write a command that will remove this student from the STUDENT table. How would your command look like if your task was to remove any student with the last name Lopez from the STUDENT table? Create an SQL command that will modify the name of course ISM 4212 from Database to Introduction to Relational Databases.arrow_forwardThree do If including downvote so far as well incorrectly. Create two different forms of the INSERT command to add a student with a student ID of 65798 and last name Lopez to the STUDENT table. Now write a command that will remove this student from the STUDENT table. How would your command look like if your task was to remove any student with the last name Lopez from the STUDENT table? Create an SQL command that will modify the name of course ISM 4212 from Database to Introduction to Relational Databases..arrow_forward134. EMPDET is an external table containing the columns EMPNO and ENAME. Which command would work in relation to the EMPDET table? a. UPDATE empdetSET ename = 'Amit'WHERE empno = 1234; b. DELETE FROM empdetWHERE ename LIKE 'J%'; c. CREATE VIEW empvuASSELECT * FROM empdept; d. CREATE INDEXempdet_idxON empdet(empno);arrow_forward
- Which of the following commands removes all orders placed before April 1, 2009?a. DELETE FROM orders WHERE orderdate < ‘01-APR-09’;b. DROP FROM orders WHERE orderdate < ‘01-APR-09’;c. REMOVE FROM orders WHERE orderdate < ‘01-APR-09’;d. DELETE FROM orders WHERE orderdate > ‘01-APR-09’;arrow_forwardTwo separate commands, DELETE and TRUNCATE, exist.arrow_forwardTask 4: The Development team of InstantStay wants to ensure that all email data of the users are lowercase. Otherwise, their login system could have problems finding the users. Therefore, they want you to ensure that each email in the table will always be lowercase after a new user is added. Create a TRIGGER called email_insert that will SET new email addresses to lowercase and run before new emails are added to the USERS table. Task: Create a TRIGGER to ensure all new email address are lowercase (SQL Database Test): Create a TRIGGER when adding new email to enforce a lowercase standard (SQL Database Test): The TRIGGER converts new emails to a lowercase formatarrow_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 Ptr
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr
dml in sql with examples; Author: Education 4u;https://www.youtube.com/watch?v=WvOseanUdk4;License: Standard YouTube License, CC-BY