I am trying to write a Power BI query that can calculate the number of ROWS with a Condition.
Now I have 5 tables- Table1
, Table 2
, Table 3
, Table 4
, Table 5
.
Now in those Tables, I have two Column Called ID
& Date
. I would like to Count all ID
where the Date
is `not Empty
I am trying this Query but it is not helping my cause.
All Total Hires =
SUMX(
UNION(
SELECTCOLUMNS(Table1,"A",Table1[Name]),
SELECTCOLUMNS(Table2,"A",Table2[Name]),
SELECTCOLUMNS(Table3,"A",Table3[Name]),
SELECTCOLUMNS(Table4,"A",Table4[Name]),
SELECTCOLUMNS(Table5,"A",Table5[Name])
)
,IF([A] <> NULL, 1, 0))
Does Anyone know any solution to this Problem?