PDF Archive

Easily share your PDF documents with your contacts, on the Web and Social Networks.

Share a file Manage my documents Convert Recover PDF Search Help Contact



ch4TAL .pdf



Original filename: ch4TAL.pdf
Title: Microsoft Word - Answers to TAL Distributors Exercises SQL Chapter 4(1)
Author: Eric

This PDF 1.7 document has been generated by / Microsoft: Print To PDF, and has been sent on pdf-archive.com on 04/10/2016 at 18:14, from IP address 129.81.x.x. The current document download page has been viewed 8243 times.
File size: 673 KB (7 pages).
Privacy: public file




Download original PDF file









Document preview


Answers to TAL Distributors Exercises
1.
SELECT ITEMNUM, DESCRIPTION, PRICE
FROM ITEM;

2.
SELECT *
FROM ORDERS;

3.
SELECT CUSTOMERNAME
FROM CUSTOMER
WHERE CREDITLIMIT >= 10000;

4.

SELECT ORDERNUM
FROM ORDERS
WHERE CUSTOMERNUM = '126'
AND ORDERDATE = #10/15/2015#;
5.
SELECT CUSTOMERNUM, CUSTOMERNAME
FROM CUSTOMER
WHERE REPNUM = '30'
OR REPNUM = '45';

6.
SELECT ITEMNUM, DESCRIPTION
FROM ITEM
WHERE NOT (CATEGORY = 'PZL');
or
SELECT ITEMNUM, DESCRIPTION
FROM ITEM
WHERE CATEGORY <> 'PZL';

7.
SELECT ITEMNUM, DESCRIPTION, ONHAND
FROM ITEM
WHERE ONHAND >= 20
AND ONHAND <= 40;
or
SELECT ITEMNUM, DESCRIPTION, ONHAND
FROM ITEM
WHERE ONHAND BETWEEN 20 AND 40;

8.
SELECT ITEMNUM, DESCRIPTION, ONHAND * PRICE AS ONHAND_VALUE
FROM ITEM
WHERE CATEGORY = 'TOY';

9.
SELECT ITEMNUM, DESCRIPTION, ONHAND * PRICE AS ON_HAND_VALUE
FROM ITEM
WHERE ONHAND * PRICE >= 1500;

10.
SELECT ITEMNUM, DESCRIPTION
FROM ITEM
WHERE CATEGORY IN ('GME', 'PZL');

11.
In Access:
SELECT CUSTOMERNUM, CUSTOMERNAME
FROM CUSTOMER
WHERE CUSTOMERNAME LIKE ‘C*’;

12.
SELECT *
FROM ITEM
ORDER BY DESCRIPTION;

13.
SELECT *
FROM ITEM
ORDER BY STOREHOUSE, ITEMNUM;

14.
SELECT COUNT(*)
FROM CUSTOMER
WHERE BALANCE > CREDITLIMIT;

15.
SELECT SUM(BALANCE)
FROM CUSTOMER
WHERE REPNUM = '15'
AND BALANCE < CREDITLIMIT;

16.
SELECT ITEMNUM, DESCRIPTION, (PRICE*ONHAND) AS On_Hand_Value
FROM ITEM
WHERE ONHAND >
(SELECT AVG(ONHAND)
FROM ITEM);

17.
SELECT MIN(PRICE)
FROM ITEM;

18.
SELECT ITEMNUM, DESCRIPTION, PRICE
FROM ITEM
WHERE PRICE =
(SELECT MIN(PRICE)
FROM ITEM);

19.
SELECT REPNUM, SUM(BALANCE)
FROM CUSTOMER
GROUP BY REPNUM
ORDER BY REPNUM;

20.
SELECT REPNUM, SUM(BALANCE)
FROM CUSTOMER
GROUP BY REPNUM
HAVING SUM(BALANCE) > 5000
ORDER BY REPNUM;

23. [Critical Thinking]
SELECT ITEMNUM, DESCRIPTION, .9*PRICE AS DISCOUNTED_PRICE
FROM ITEM;


Related documents


ch4tal
ch4tal qa
how to create private pages for customers in volusion
online returns form
magento extensions to further improve1738
block chain software 4


Related keywords