TIMESERIES UNTIL tomorrow query

Hello all - is it possible via to write a TIMESERIES query that covers SINCE today UNTIL the end of the day?

For example, I can write one that covers the start of the week until the end of the week by explicitly using: SINCE monday UNTIL sunday
SELECT count(*) FROM PageView TIMESERIES 1 hour SINCE monday UNTIL sunday COMPARE WITH 1 week ago

However I’d like that for 1 day, and it should roll over at midnight e.g. SINCE today UNTIL tomorrow

This way I can see a graph of the expected trend for rest of the day against what we seen so far

Hi, @rupesh1122: Have you tried just SINCE today?

Re-reading your question, I think you want to show the full day from 1 week ago, even if it is the middle of the current day. I do not think that is possible; COMPARE WITH can only show the same time window from two different days, weeks, etc.

Hi Phil - Let me share an example, in this query

SELECT count(*) FROM PageView TIMESERIES 1 hour SINCE today UNTIL friday COMPARE WITH 1 week ago

I can see all the PageView’s from today and a trend compared to last week until the end of today day - however I’ve had to hardcode tomorrows day (Friday).

Is it possible to have tomorrows day as a dynamic value? (that stays relative like ‘today’ or ‘this week’ do)

I don’t know of a way to do that. Maybe someone else will have a suggestion.

1 Like

I like that this is at least possible at all. I like what you are trying to do there and hope that NR can solve this need.

1 Like