foxlover2012
Programmer
Hi All,
Question about an SQL statement and how to achieve this.
I want to show all records from table A and only certain records from B.
Table A - Master Inventory File (ALL ITEMS SHOULD SHOW)
Item #, Description, Price
38293, Paint, 9.99
29839, Brush, 3.99
38921, Bolt, .23
Table B - Order Detail Table (Only records matching an orderid will show)
Order ID, Qty Ordered, Item #
1000, 10, 29839
Basically I want my cursor to look like this
Result..
Item Number, QTY Ordered, Description, Price, Orderid
38293, Null, Paint, 9.99, NULL
29839, 10, Brush, 3.99, 1000
38921, Null, Bolt, .23, NULL
The kicker is that I want to show ALL items in table A (the main inventory table) even if they ARE NOT in the order file.
Basically what I want to achieve is the ability to see ALL items at the same time I can see items on the order.
Thanks for any help, John
Question about an SQL statement and how to achieve this.
I want to show all records from table A and only certain records from B.
Table A - Master Inventory File (ALL ITEMS SHOULD SHOW)
Item #, Description, Price
38293, Paint, 9.99
29839, Brush, 3.99
38921, Bolt, .23
Table B - Order Detail Table (Only records matching an orderid will show)
Order ID, Qty Ordered, Item #
1000, 10, 29839
Basically I want my cursor to look like this
Result..
Item Number, QTY Ordered, Description, Price, Orderid
38293, Null, Paint, 9.99, NULL
29839, 10, Brush, 3.99, 1000
38921, Null, Bolt, .23, NULL
The kicker is that I want to show ALL items in table A (the main inventory table) even if they ARE NOT in the order file.
Basically what I want to achieve is the ability to see ALL items at the same time I can see items on the order.
Thanks for any help, John