Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
revansh
Helper IV
Helper IV

Data Modelling Design Help

Hi,

 

I have 3 fact tables and 1 dimension table .

 

FCT1:  Country | Sales Amount

FCT2:  State      |  Sales Amount

FCT3:  City  | Sales Amount

DIM:  Country | State | City

 

How do i join above 4 tables to create reports to drill through from COUNTRY  to STATE to CITY.

 

Thanks

5 REPLIES 5
dramus
Continued Contributor
Continued Contributor

From the details you have given. How do you know which State and Country a City belongs to, or which State a Country is in?

 

Without that, you can't drill down.

Hi Dramus,

 

Country to STATE to city link is in dimension table.

 

for eg:

 

US   KY LOUISVILLE

US   KY LEXINGTON

US   KY FRANKFORT

 

Thanks

dramus
Continued Contributor
Continued Contributor

So at the City level, how do you tell Boston US, from Boston UK?

DATA IN FACT TABLE IS LIKE THIS.

 

FCT1: COUNTRY |  SALES AMT

FCT2: COUNTRY | STATE | SALES AMT

FCT3: STATE |  CITY  |  SALES AMT

 

Hope it is clear now.

 

Thanks

dramus
Continued Contributor
Continued Contributor

Okay...So Assuming that the City table has the full key (City/State/Country).

 

Power BI can only handle single field keys, so you will need to create some composite keys. (e.g. State-Key = [Country] & "|" & [State]) on the FCT2 and FCT3 tables. You will also need to create a city-key (Country/State/City) on the DIK and FCT3 tables

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.