Forum Discussion

arndtvissing's avatar
arndtvissing
Frequent Visitor
7 years ago
Solved

Crossjoining metric

Hi all

 

Im trying to create a dimension in my power bi report that would allow me to filter on multiple attributes in the fact table.

 

I have 1 fact table like:

 

Import Country

Export Country

Sales

 

I would like to create a dimension that allows the users to have a Export/Import Country dimension. That would cross join the fact. I know i could essentially enhance my fact table on the database side with an import/export flag, and essentially double the fact table in size, but i want to avoid that since my fact table is 300 million records big.

 

Imagine the fact table looks like this:

 

Booking              Export               Import                 Sales

A                          US                    Germany              5

B                          US                     Brazil                   3

 

I would like to be able to generate the following data matrix

 

Location Export/Import                 Booking                   Sales

US                                                    A                             5

Germany                                          A                             5

US                                                     B                             3

Brazil                                                B                              3

Total                                                                                16