AnsweredAssumed Answered

SQL Arrays aggregation

Question asked by iconomydk on Apr 11, 2016
Latest reply on Apr 13, 2016 by user19752

Goal to see total sales for item group in time period

Problem I have 2 different line-item tables which uses same item group

 

With two SQL statements I get the following (Itemgroup no. | Sales | Profit)

 

$Table 1

5|100|25

6|125|30

7|150|40

 

$Table 2

5|50|10

6|70|20

7|60|30

 

now I would like to aggregate these 2 arrays into:

 

5|150|35

6|195|50

7|210|70

 

How can this be done ?


Thanks Lars

Outcomes