how i can get multiplication of all value os single column
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: how i can get multiplication of all value os single column

  1. #1
    Join Date
    May 2002
    Posts
    3
    hi
    by sum function we can get the sum of can field by his query
    select sum(xyx) from table_name;
    but if i want the multilication of all the value how i can get.

  2. #2
    Join Date
    May 2002
    Posts
    108

    Question not clear !

    Hi

    I couldn't follow your question. Can you be a little clearer.

    Of course you can multiply fields in a table to produce a summary

    select sum(x*y*z*x) from table_name

    Is this what you want?

    Cheers
    Nandu



    Never give up !

    Nanda Kumar - Vellore

  3. #3
    Join Date
    Apr 2002
    Posts
    14
    If you want to multiply all the values in one column for all rows in a query try using natural logs (though you will possibly loose precision).

    select exp(sum(ln(column))) from ...


    I suspect that there might be functions to do this in later versions of Oracle 8i to support easier data warehousing but I'm not sure.

Posting Permissions

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



Click Here to Expand Forum to Full Width