i have two tables production.product(and sales table and i want to get the total unit

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tigistgetachew
    New Member
    • Oct 2020
    • 1

    i have two tables production.product(and sales table and i want to get the total unit

    Production.prod ucttable(produc tid, productcategory , modifieddate and sales table( salesorderid, productid, ,quantity,unitp rice,modifiedda te,orderdate) so i want to get the total amount of unit solid from this two table. How can i write my query?
  • Banfa
    Recognized Expert Expert
    • Feb 2006
    • 9067

    #2
    Code:
    SELECT productid, SUM(quantity) FROM sales GROUP BY productid

    Comment

    Working...