Hi everyone.
I’m sending out the year to date numbers every evening around 11 pm. The intention was to capture at the end of the day so when switching months or quarters, the last email will show everyone the final numbers for the month/quarter.
I just realized, that unfortunately this does not work since the PBI server runs on UTC. I’m on pacific time. The screenshot below shows the email that was sent out on 2/28 at 11 pm and the month field already switched to March.
I found a lot of videos that show how to display the right update timestamp, but I didn’t find anything that addressed this issue. Since I don’t have a date/time field, but only a date field in my date table (I use the enterpriseDNA query for the date table), I don’t know how to accomplish this.
Thank you very much for any help.
Nico
Hi Keith,
Thank you very much. These are the videos I found and watched but for some reason I’m not able to wrap my head around how to make this work in my case. In the videos I watched, it was all about a time stamp. But I don’t have a time stamp. I only have a date stamp from my date table and brining in a time does not make any sense.
I apologize if this is a duplicate post, but I just don’t understand how this helps me.
Thanks,
Nico
could get the time stamp within the data file from the service to be included? then you can switch to your time that is done in the posting within the forum.
did you check out the posting link that i sent. that might help too
Hi,
apologies for not getting back. I carved out some time today to take a look at this and hopefully I will resolve this or come back with more questions.
I connect the date field to the dates in all my other tables. There is no time field and I don’t understand how I should bring a time stamp in there and convert that to a date that is offset by 9 hours. Sorry for making this more complicated then it is but my brain just doesn’t get it.
You could do something like this to offset a date by 9 hours from UTC CurrentDate = Date.From( DateTimeZone.FixedUtcNow() + #duration( 0, -9, 0, 0))
As for the visual display, are you using relative datefilters? If so and its still giving you issues, you might want to switch to Offsets instead, from the code you’ve showed I can tell you’re using the legacy date table not the extended one. You can find that here.
.
This extended date table includes Offsets, which are relevant to the CurrentDate on line 5, you will need to replace the M code with the line above - as depicted here.
Melissa,
Thank you so much for your answer and this detailed explanation. I have made the changes in my report. I’m hoping to see the changes tomorrow.
I tried to do some testing but it didn’t really work out so I decided just to wait.
I’ll provide an update tomorrow.
Thanks again,
Nico
It’s working as expected for me, ofsetting the current date in the date table by hours. As shown here, refresh took place April 7th but “todays date” in the date table is April 6th.
I’ve attached my sample, so you can give this a go as well. Determine the required number of offset hours and update the CurrentDate in inside the function query: utcCalendar
Hi Melissa.
Thank you very much. I can confirm that your file is working on my side as well. I will try to figure out where my file has an error and update.
Hi again.
I copied your date query into my file and it seems to be working now. I had a lot of Measures using the today() function in my file. I replaced them all with measures referencing the date table. If you don’t hear back from me, this means everything worked. Thank you so much for your help!!!
Have a great weekend.
Nico