0 Replies - 6288 Views - Last Post: 08 March 2013 - 08:59 AM

#1 vbnewbeginer  Icon User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 53
  • Joined: 25-July 12

Joining 2 tables with other commands in oracle

Posted 08 March 2013 - 08:59 AM

I have 2 tables namely, Stocks and Sales1

Data for STOCKS is:

Item number Description Price Qty on Hand

1001 Agedashi 95 100
1002 Kushi 170 100
1003 Gyoza 120 100
1004 Tonkatsu 145 100
1005 Karaage 145 100
1006 Sukiyake 300 100
1007 Ebi 200 100
1008 Ika 180 100
1009 Sakana 205 100
1010 Wasabi 95 100

----------------------------------------------------

Data for SALES1 is:

Item number Qty Bought

1009 1
1010 1
1002 2
1009 1
1004 1
1007 1
1003 1
1008 1
1007 1
1006 1
1010 1
1001 2
1005 1
1006 2
1001 3
1009 1
1007 1
1008 1
1004 1
1005 1
1006 1


I don't know the commands that i will use to this problems, can anyone help me?

a) Display the item number, description and quantity bought for the product with item number is 1001.
B) Display the description, total quantity bought and total number of buyers all products sold.
c) Display the description and stocks left for each product. (Hint: Stocks left = Quantity on Hand less Total Quantity Bought)

Is This A Good Question/Topic? 0
  • +

Page 1 of 1