Skip to main content
Announcements
Accelerate Your Success: Fuel your data and AI journey with the right services, delivered by our experts. Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Is there the need to aggregate data in a table?

Hello All,

I would like some advise about designing my cube.

I have a table with all the invoice lines. One invoice can spread on multiple lines (for example 2 products, 1 discount, 1 delivery fees, so a total of 4 lines here)

Facts table :

- OrderNumber

- Line type

- Amount

Now I need some basic information like

- number of orders

- average basket

My question is :  Is it easier to work directly on this table only (for example with a count(distinct()), or is it better to create a table that will aggregate the data? For example :

Aggr Data :

load

   OrderNumber,

   1 as OrderecordCount,

   sum(amount)

from Facts

group by OrderNumber

Thank you in advance,

MT

0 Replies