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
NAOS
Advocate III
Advocate III

Relations between tables

Hi everyone,

 

I'm fairly new to Power BI and I'm stuck with modeling my data.

 

I got three tables,

 

One with energy production data for different countries and years by Product (Coal, Nucler, Natural gas, Renewables, etc) and another column with the flows of that energy (Imports,Exports, Domestic production, Transformation, Final consumption, etc).

 

The second column also contains the country name and year column but with the amount of electricity produced by each country during each year.

 

The third table contains the CO2 emissions by country and by year.

 

I could connect the three tables with a fourth table containing the countries' names, but I can't get to relate them by year.

 

Any suggestions?

 

Thanks in advanced,

 

NAOS

1 ACCEPTED SOLUTION
MFelix
Super User
Super User

Hi @NAOS,

 

Based on your explanation the best way would be to do a table with countries and another one with a calendar and make the relatioinship between these two tables and the other 3.

 

Check this link to create a calendar table on Power BI, however if you google it you will get lot's of different ways to make calendar tables in DAX or M language.

 

Regards,

MFelix

 

 


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

2 REPLIES 2
MFelix
Super User
Super User

Hi @NAOS,

 

Based on your explanation the best way would be to do a table with countries and another one with a calendar and make the relatioinship between these two tables and the other 3.

 

Check this link to create a calendar table on Power BI, however if you google it you will get lot's of different ways to make calendar tables in DAX or M language.

 

Regards,

MFelix

 

 


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Hi @MFelix,

Thanks a lot for your answer. It worked well.

Kind regards,

 

NAOS

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.