Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical

Re^2: array of arrays calculations

by rocky13 (Acolyte)
on Jan 20, 2011 at 02:28 UTC ( #883229=note: print w/replies, xml ) Need Help??

in reply to Re: array of arrays calculations
in thread array of arrays calculations

First, i updated the query in the question little bit to simplify the understanding of the question. As you can see, there are multiple rows for each cus, ta, gd1, gd2 and number of rows in one table is not the same as number of rows in other table.Thus, I think it would be best to group them by cus, ta while getting the sum of gd1 and gd2. I thought maybe there is a way with "union all". I did get the solution by using a hash for each and then doing the computation. However, if there is a way to do it just using sql query, I would love to know. Thanks!

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://883229]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2018-05-21 06:16 GMT
Find Nodes?
    Voting Booth?