[HW 3.4c] SQL Basics – Part 2

Using the same data set as yesterday, please prepare the following in SQL:

1. A listing by region name of all employees …. Two columns, just the name of the region and the name of the employee.
2. A listing by region name of the first 15 customers in the North region: Two columns, just the name of the region and the name of the customer.
3. A report showing the largest 15 transactions, including the product name and the employee who made the sale for Feb 11, 2013.  It should return the following fields:Transaction Date, Prouct Name, Employee Name, Transaction Amount

4. A query that will produce a “complete and verbose dataset” of the transactions table. In other words, the transactions table joins with the employee table, the customers table, and the products table. Join these tables into a single larger table which includes the fields: cust_id, product_id, emp_id, as well as the names of each customer, product, and employee.  To do this, you will need to JOIN the transactions table with the others.

For questions 1-3, turn in your SQL statements and the output you produced.
For question 4, Just turn in your query, not the data.

8 comments

  1. barroyo2015 · · Reply

    How does one figure out “largest transactions” for products that have the same ‘txn_amount’?

    Like

  2. What are you finding?

    Like

    1. barroyo2015 · · Reply

      For question #3

      Like

      1. How many transactions are there on Feb 11, 2013?

        Like

  3. barroyo2015 · · Reply

    a lot

    Like

  4. there were more than 50,000 I think

    Like

  5. Not on that specific date

    Like

Leave a comment