Forum Discussion
How to get counts of temp table variable ?
- Anonymous4 years ago
I'll figure out the remaining on it. I appreicate the push in the right direction, it's defenitely closer and almost there. Thanks again.
Anonymous maybe create a measure, you don't need to create a temp table:
Measure =
VAR __unionTable = UNION ( .... )
RETURN
SUMX (
SUMMARIZE (
__unionTable,
[Fical_Year_Week Column],
"@Count", COUNTROWS ( __unionTable )
),
IF ( [@Count] > 1, 1 )
)
If this measure is not blank, it means there are overlapped dates, otherwise it will give the count of dates that are overlapped.
✨ Follow us on LinkedIn and to our YouTube channel
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.
- Anonymous4 years agoNot applicable
I think it's getting closer, thank you - but not quite there yet.
If I just look at the inner (Summarize) Part of the function, and put it in a table temporarily (later I'll put it in a measure), to see what's going on, the Counts seem much higher, as there should only by 6 distinct counts of each fiscal_year_week, instead of the 942 it's reporting.