January 10, 2025 at 3:27 pm
I have a measure with totals for specific dates with the LastNonEmpty aggregation, and a measure with turnovers with the Sum aggregation.
Help create a measure with totals for each day that would take into account the last known totals + turnovers from the date of the last totals to the current date.
I tried to get the date of the last totals for each date with this request
WITH
MEMBER [Measures].[LastNonEmptyDate] AS
tail(
filter(
periodstodate([date].[calendar].[Date Key],[date].[calendar].currentmember),
NOT ISEMPTY([Measures].[totals])
), 1
).item(0).member_caption
SELECT
{ [Measures].[LastNonEmptyDate] } ON COLUMNS,
[date].[calendar].[Date Key].MEMBERS ON ROWS
FROM [test]
I get null for all members except those where the current date matches the totals date let's say there are totals for 20240101 for 20240101 I get the date 20240101, and for 20240102 it's already null, although the intended value should be 20240101
January 11, 2025 at 4:10 pm
Thanks for posting your issue and hopefully someone will answer soon.
This is an automated bump to increase visibility of your question.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy