The Interactive report is published here, you can download the PBIX here.
In PowerBI or Tableau or any BI solution by defaults when you have multiple slicers, the filter conditions is always, AND, in this particular case, the user want to filter a schedule based on a start date OR the end date OR the activity status, basically how to reproduce the following Primavera Filter using DAX
Using the normal slicers will not work as it will simply show the activities where all the conditions met, instead we will use some DAX techniques (disconnected slicers and filter using the result of a measure) to get a new behavior.
Let’s build a simple data mode.
1-The main table is task: it contains Activity ID, Activity Status, Start, Finish
2- add a date Table, Start_Date, don’t link it to any table, use it in a slicer , the table is generated using Powerquery,
3- add another Date Table, Mstdate, don’t link it either, use it in a slicer
4- add Activity status Table, don’t link it, , use it in a slicer
5- add this measure
Filter_measure = CALCULATE(COUNTROWS(task),
FILTER(task, ([Start] <= LASTDATE(Start_Date[Date])
&& [Start]>= FIRSTDATE(Start_Date[Date]))
([finish] <= LASTDATE(Finish_Date[Date])
&& [finish]>= FIRSTDATE(Finish_Date[Date]))
IF(NOT(ISFILTERED(‘Activity status'[Activity status])),BLANK(),’task'[Activity status]IN ALLSELECTED(‘Activity Status'[Activity Status]))))
Add this measure to the matrix visual as a filter only, and make it not equal null, and voila
4 thoughts on “Using Or Conditions between Slicers to filter Primavera Schedule using DAX”
Hi. How to import the P6 data into MS Power BI?
LikeLiked by 1 person
either you export using excel, or just connect to the database (oracle, SQL server )
Hello mim, I am currently looking at P6 data more specifically at tasks predecessors and successors.
I am trying to be able to filter a task and see all the activities that have a direct logic link and the ones with an indirect link ( the successors of the successors).
Have ever tried this and have some tips you can give me?
LikeLiked by 1 person
you want to filter the path, I tried and it is a pain,, and i could not find a proper solution, but will let you know later