I have a constantly increasing counter e.g.
my_counter{uid="1", srv="a"}
my_counter{uid="1", srv="b"}
my_counter{uid="2", srv="a"}
my_counter{uid="2", srv="b"}
...
and I'd like to build a Grafana dashboard to show what is the diff of the value today (since midnight to now).
This is the query that I came up with sum(increase(my_counter{}[$__range])) by (uid) and the $__range is selected as "Today so far" in Grafana.
I would imagine that the "start" value should not matter in this case and the graph should always start from zero since it should be calculating delta's from midnight to now, but that does not seem to be the case.
What would be the best approach to figuring out what is wrong with the query or maybe I am completely misunderstanding how increase function works in this case?
Thanks in advance.
EDIT (2020-06-24 16:04 CEST):
I think I am misunderstanding how this works and my question is a bit unclear. To get the count for today I would like to see the value(my_counter at now) - value(my_counter at 00:00(CEST))
Is that even doable in Grafana?
