Results 1 to 2 of 2

Thread: Decode.....

  1. #1
    Join Date
    Jul 2012

    Unanswered: Decode.....

    Hi All,

    Could someone please help me in getting a query.

    I am having a table with following data:

    Date Product_name Quantity_sold
    12/6/2012 Product1 1
    12/7/2012 product2 3
    12/6/2012 product3 4
    12/7/2012 Product1 2
    12/7/2012 product2 1
    12/6/2012 product3 5
    12/7/2012 product3 3
    12/6/2012 product2 4

    Now I want this data in following manner:

    For each date - how much is the Total quantity sold , sum of Product1 sold,Sum of product2 sold,etc.
    I am having more than 50 products in my table.

    date Quantity_sold Product1 Product2 Product3
    12/6/2012 14 1 4 9
    12/7/2012 9 2 4 3

    I was trying this by decode but the sum of the product was not correct.

    could someone please help me on this!!!!


  2. #2
    Join Date
    Aug 2003
    Where the Surf Meets the Turf @Del Mar, CA
    Provided Answers: 1
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts