How to use a measure in another table with many to many relationship

pjmorris

Well-known Member
Joined
Aug 2, 2012
Messages
2,172
Office Version
  1. 365
Platform
  1. Windows
Hi,


I have two tables:


1. a Task Table: 'tblTask' containing [title], [sub title], [booking group] and [effort]. the first three fields are text strings and the fourth is a percentage.

2. a Resource Table: 'tblResource' containing [date], [booking group] and [available effort].


The Resource Table is linked to a calendar table that allows the effort available per accounting period to be calculated. Thus for example [booking group]=”ILS” and accounting period AP-1: [ActualAvailableResource] = 391.29 hours, which is correct, this measure works for other combinations of [Booking Group] and tblCalendar[Accounting Period].


I now need to calculate:

tblTask[effort] * tblResource[ActualAvailableResource]

This appears to work, but the Calender filter created by having the [Accounting Period] as a column heading isn’t applied to the tblResource and hence the result is incorrect. I feel that this is because the tblTask isn’t linked to either the tblCalendar or, because of the many to many relationship, to tblResource.


If anyone can suggest how to go about this I’d be really grateful.


Regards


Peter
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
Apologies – I misunderstood what was happening!


After further investigation I can see that the tblResource is being filtered by the date. It is not being filtered by [Booking Group]. Ive now tried using the following:


=sum(tblTasksSimple[Effort])*calculate([ActualAvailableResource],tblResource[Booking Group]) without success.


and [ActualAvailableResource]=sumx(tblResource,tblResource[Available Hrs]*RELATED(tblCalendar[Daily % of Annual]))


Hope this helps.


Regards


Peter
 
Upvote 0

Forum statistics

Threads
1,223,897
Messages
6,175,270
Members
452,628
Latest member
dd2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top