Oracle 12c: SQL
Oracle 12c: SQL
3rd Edition
ISBN: 9781305251038
Author: Joan Casteel
Publisher: Cengage Learning
Expert Solution & Answer
Book Icon
Chapter 9, Problem 3HOA

Explanation of Solution

SQL Query:

Refer to the “books”, “orders”, “orderitems” and “customers” tables in the JustLee Books database.

The SQL statement to perform the stated task with traditional approach is as follows:

SELECT DISTINCT c.lastname, c.customer#

 FROM books b, orders o, orderitems i, customers c

 WHERE c.customer# = o.customer#

  AND o.order# = i.order#

  AND i.isbn = b.isbn

  AND c.state = 'FL'

  AND b.category = 'COMPUTER';

The SQL statement to perform the stated task using the JOIN keyword is as follows:

SELECT DISTINCT c...

Blurred answer
Students have asked these similar questions
7. List all customers who were referred to the bookstore by another customer. List eachcustomer’s last name and the number of the customer who made the referral.
Task 11: Find the ID, first name, and last name of each customer whose first name begins with the letter S.
- Delete the employee who has the longest employment in the company
Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
  • Text book image
    Oracle 12c: SQL
    Computer Science
    ISBN:9781305251038
    Author:Joan Casteel
    Publisher:Cengage Learning
    Text book image
    A Guide to SQL
    Computer Science
    ISBN:9781111527273
    Author:Philip J. Pratt
    Publisher:Course Technology Ptr
Text book image
Oracle 12c: SQL
Computer Science
ISBN:9781305251038
Author:Joan Casteel
Publisher:Cengage Learning
Text book image
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr