From 0935526d232d716d852566a3aa399ad663cd881d Mon Sep 17 00:00:00 2001 From: Sven Klemm Date: Thu, 12 Jul 2018 10:13:21 +0200 Subject: [PATCH] partition by metricColumn when using increase --- public/app/plugins/datasource/postgres/postgres_query.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/app/plugins/datasource/postgres/postgres_query.ts b/public/app/plugins/datasource/postgres/postgres_query.ts index 9a36a838c82..9e32736b405 100644 --- a/public/app/plugins/datasource/postgres/postgres_query.ts +++ b/public/app/plugins/datasource/postgres/postgres_query.ts @@ -245,7 +245,7 @@ export default class PostgresQuery { } switch (special.params[0]) { case 'increase': - query = query + ' - lag(' + query + ') OVER ()'; + query = query + ' - lag(' + query + ') OVER (' + over + ')'; break; case 'rate': let timeColumn = target.timeColumn;