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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
cristianml
Post Prodigy
Post Prodigy

Compare in one table from two different queries

Hi,

 

I need to compare 2 queries: one called FORECAST and other ACTUAL. These 2 queries have same format data with : resources, hours, Payroll, Date data.

 

The problem is that sometimes in one of the queries has no data for a particular resource and when I use the Slicer to filter by a month period, It doesn't show this resource cause is not in both sides/queries. How can I solve this ?

 

Thanks and regards,

 

1 ACCEPTED SOLUTION

@cristianmlhave you tried creating a relationship between the Forecast and Actual table?  If so, which way is it going?  

 

Another option might be to create a "Resource" table with the names listed and join both tables to that. Then use that name as the item on your grid.

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

Hi cristianml,

 

If I am correct, you are trying to show all resources even if it doesn't have record at a specific period. To do so, you may need to create a look-up table of all resources and use the field in that table in your visuals.

 

If you can provide data sample, It will be clearer. Thanks.

 

Hi,

 

What we are trying to do is a comparison of resources hours/Payroll between 2 data tables (Actual and Forecast). Considering also that we need to filter by Date/Period and category. Not sure if vlook-up is usefull in this case cause every month we have new resources coming (in Actual version) and other resources that we need to remove. Forecast version (table) is base of comparison for every month, so in Actual version we found new resources and remove others. Is there any way we could avoid manual work in PBI ? The idea is if could automate by only refreshing the data so we we see the comparison table as the example below for your review and coments. I could't find attach file field here.

 

Thanks in advance for your help.

 

 

Analysis.jpgPBI Photo.jpg 

Cristian

@cristianmlhave you tried creating a relationship between the Forecast and Actual table?  If so, which way is it going?  

 

Another option might be to create a "Resource" table with the names listed and join both tables to that. Then use that name as the item on your grid.

Hi, 

 

Yes it worked !. I appended both names tables leaving relationships as the attached photo. :).  Now I have to add another just for category and done.  

 

Relationships.png

Thanks for your help ! 🙂

 

Regards 

Yay!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.