Simple SQL Query Question

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Simon Bigwood

    Simple SQL Query Question

    Hi
    I have a table of containing a list of products that looks a bit like this
    Product Qty Available Allocated Sold
    CPZ 2 True False False
    PDA 5 True False False
    CPZ 2 False False True
    HDP 8 True False False
    CPZ 2 False False True
    PDA 3 False True False
    DEE 1 True False False

    I want to make an SQL query so that i can show a summary of the products in
    stock.
    I,e i would like the query to look like this.
    Product QtyAvail QtyAlloc QtySold
    CPZ 2 2 2
    PDA 5 3 0
    HDP 8 0 0
    DEE 1 0 0

    Can anyone give me any ideas on how to start this query, becuase i cannot
    work it out and it is driving me crazy??



Working...