March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hello,
I have a relatively easy question (I guess) that I cannot find the solution.
In the table below, I want the last column (TotalActiveDays) to show the total number of days (252) in each line, as I am showing
Thanks
Solved! Go to Solution.
What you propose is not working.
What I have done though, is to create a new table named "Dates" summarising the dates
dates = DISTINCT(OrderBase[OrderDate])
and then I have created a measure to calculate them
GrandTotalActiveDays = COUNT(dates[OrderDate])
Not sure if it is the optimum way, however it worked
Or when i'm looking at this more closely, do you want the totalactivedays to reflect the highest value of activedaysorderbase?
Thanks for the answers.
I don't want the totalactivedays to reflect the highest value. In this example, the highest is 251 whereas the total is 252.
Additionally, I don't want to equal it with a specific value as a column because I want it to be dynamic when I am refreshing the database. For example, if another dataset has 300 distinct active days, I want the TotalActiveDays column to have the value 300 in each row.
Therefore, I guess I need to do that with a measure like:
TotalActiveDays = CALCULATE( DISTINCTCOUNT(OrderBase[OrderDate]),XXXXX)
Play around with Measure = Distinctcount(all(Table[Column]))
Since i cant view your dataset i cant really specify which column you should count the rows of!
/ J
What you propose is not working.
What I have done though, is to create a new table named "Dates" summarising the dates
dates = DISTINCT(OrderBase[OrderDate])
and then I have created a measure to calculate them
GrandTotalActiveDays = COUNT(dates[OrderDate])
Not sure if it is the optimum way, however it worked
Right, it's been a long day... Distinctcount is for columns and distinct for tables.
That should work, glad it worked out!
/ J
Create a calculated column and equal it to 252 then display that column in the visual. The column should be in the same table as SKU.
This should work if 252 is a constant, if it needs to be dynamic in some way you will need a different formula.
/ J
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
125 | |
84 | |
67 | |
54 | |
43 |
User | Count |
---|---|
203 | |
106 | |
98 | |
65 | |
56 |