From 97d1676fe822d66afaee1374f3995049bef791d8 Mon Sep 17 00:00:00 2001 From: Louis Ventre Date: Mon, 7 Aug 2017 09:26:32 +0200 Subject: [PATCH] Add time extremity with InfluxDB (#8722) --- public/app/plugins/datasource/influxdb/datasource.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/public/app/plugins/datasource/influxdb/datasource.ts b/public/app/plugins/datasource/influxdb/datasource.ts index dc9b83223fa..10f6d47f0b9 100644 --- a/public/app/plugins/datasource/influxdb/datasource.ts +++ b/public/app/plugins/datasource/influxdb/datasource.ts @@ -263,10 +263,10 @@ export default class InfluxDatasource { var fromIsAbsolute = from[from.length-1] === 'ms'; if (until === 'now()' && !fromIsAbsolute) { - return 'time > ' + from; + return 'time >= ' + from; } - return 'time > ' + from + ' and time < ' + until; + return 'time >= ' + from + ' and time <= ' + until; } getInfluxTime(date, roundUp) { @@ -287,4 +287,3 @@ export default class InfluxDatasource { return date.valueOf() + 'ms'; } } -