Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I need some help with the following. I have a dataset consisting of different matches and their historical stages. I want to calculate how many of those matches have stage "3.1 | Kandidaat voorgesteld aan klant" and from those how many also have stage "4.0 | Kandidaat mag op gesprek bij klant". In SQL it would look like this:
select *
from matches_hist mh
where mh.stage = '4.0 | Kandidaat mag op gesprek bij klant' and mh.matchID in
(select distinct mh.matchID
from matches_hist mh
where mh.stage = '3.1 | Kandidaat voorgesteld aan klant'
)
I have troubles with the second part in the SQL code
mh.matchID in (select distinct matchID
from matches_hist mh
where stage = '3.1 | Kandidaat voorgesteld aan klant'
)
I have tried using values(), but I am not able to add the condition stage = '3.1 | Kandidaat voorgesteld aan klant'
Could anyone help me with this problem?
Thanks in advance!
Regards, Gino
Solved! Go to Solution.
I was able to find a solution myself. For the people wanting to know. You can use the functions calculatetable(values(), <filter conditions>).
I was able to find a solution myself. For the people wanting to know. You can use the functions calculatetable(values(), <filter conditions>).
User | Count |
---|---|
25 | |
12 | |
8 | |
6 | |
6 |
User | Count |
---|---|
26 | |
12 | |
11 | |
10 | |
6 |