Questions tagged [influxql]

Use this tag for questions related to InfluxQL, an SQL-like query language for interacting with data in InfluxDB.

219 questions
0
votes
1 answer

InfluxQL to Flux

What is the equivalent of this query select sum("count") from "measurement_name" where timenow()-4d group by time(100s),"source" in Flux? I have tried from(bucket:"metrics/default_metrics") |> range(start: -4d) |> filter(fn:…
Niko
  • 616
  • 4
  • 20
0
votes
1 answer

Data not returning from query when using Node but does from console | InfluxDB

I have a Node.js application that I am trying to get to query InfluxDB's cloud offering, I have set it up so I can write data fine now I need the query part. My data contains a few values - or will anyways - I have an elapsed time, service, and…
joshk132
  • 1,011
  • 12
  • 37
0
votes
1 answer

Setting up telegraf config file to enable data ingress

I want to use grafana to monitor data, utilizing the mathematical abilities of the FLUX query language. For this purpose, I've set up an influxdb and a grafana server, and I installed telegraf. user@Logger-0271:~$ influx Connected to…
cheesus
  • 1,111
  • 1
  • 16
  • 44
0
votes
1 answer

How can I normalize the time series in InfluxDB?

The goal is to create the time series normalized on the first value of the time frame. For example, we have the series time | value ------------------------------ 2020-07-13T00:00:00Z | 2 2020-07-14T00:00:00Z | 4 2020-07-15T00:00:00Z…
nkrivenko
  • 1,231
  • 3
  • 14
  • 23
0
votes
1 answer

Retrieve all last points/records per tag in InfluxDB, without WHERE clause

I have roughly 1500 devices which, at random frequencies, push data to my InfluxDB v1.8+ instance. I am looking for the most efficient way, at least in terms of performance, to collect the last point for each device_id (tag). For the sake of brevity…
Juliën
  • 9,047
  • 7
  • 49
  • 80
0
votes
1 answer

How to get data in InfluxDB subscription end point?

Hi I have created a subscription (http) in the InfluxDB using following command : CREATE SUBSCRIPTION "test-data-update" ON "system_managment"."system_managment2d" DESTINATIONS ALL 'http://localhost:9001/ts/data-update' And in the ExpressJs app…
Dipak
  • 6,532
  • 8
  • 63
  • 87
0
votes
2 answers

How to escape forward slash '/' within a regex condition in flux query

I have to query an InFlux database and match a particular string within one of columns. something like: WHERE (\"namecache\" =~ //) however, the could itself contain '/' characters. I am unable to escape the forward…
0
votes
1 answer

How I get specific row during query from two tables in Influx

I tried to write a query to Influx Database in below example: I have two tables: table_1 id | value 1 | 100 2 | 200 table_2 id | value 1 | 900 2 | 800 I want to use one query to gets rows: id 1 and 2 from table_1 and id 2 from table_2 In…
Damian Tokarczyk
  • 529
  • 1
  • 4
  • 11
0
votes
1 answer

InfluxDB WHERE clause on a 'High Cardinality' field (or a tag)

I'm playing with InfluxDB and trying to experiment it for a vehicle speed tracking usecase. Every vehicle's speed at a given time is stored as a data point. I'm modelling "vehicle_registration" as a tag and other values as fields. I'd want the where…
user1189332
  • 1,773
  • 4
  • 26
  • 46
0
votes
2 answers

InfluxQL/Grafana: Get maximum per day

I want to get the maximum of a time series per day, so one data point each day at time 00:00:00. The maximum should be calculated over the range 00:00:00 until 23:59:59 for each day. What i got so far: SELECT max("temperature") FROM "Temperature"…
Marvin Noll
  • 585
  • 1
  • 7
  • 23
0
votes
1 answer

InfluxDB elapsed time based on a specific value

Just new to InfluxDB. I have a monitored IO signal that everytime it is changed then InfluxDB will record its timestamp. The data is like below: time value ---- ----- 2020-03-19 06:02:50 0 2020-03-19 06:01:28 …
Sean Hsieh
  • 305
  • 2
  • 13
0
votes
0 answers

ExecuteInfluxDbQuery Processor throwing Null Pointer Exeption in NiFi

I am trying to retrieve data from my influx database using the following query : select * from signal But as soon as I run the processor I get the "Null Pointer Exception. Here's what my processor looks like : I have tried retrieving data from…
Shrads
  • 883
  • 19
  • 39
0
votes
1 answer

Add day to InfluxDB query select clause

Hello, people. Is there a way to add days to an InfluxDB query, like we do in MySQL? Something like this: SELECT time + 1d, last(field) AS point FROM measurement We can use time literals in the WHERE clause, but can we use them on the SELECT…
Félix Daniel
  • 21
  • 1
  • 7
0
votes
1 answer

Is there a way to specify the field-key when using the INTO statement?

I have the need to combine two measurements into one single measurement for cross-measurement operations, but both of the measurements only have one single field-key "value". (I know, that this is not a "pretty" Schema Design and I know about Flux…
fxweidinger
  • 173
  • 2
  • 11
0
votes
1 answer

Influx Query for extracting data in a certain format

I have the following data as input in kafka_consumer: time Mode 2020-01-22T10:50:04.623699901Z ABC 2020-01-22T10:50:22.344965434Z ABC 2020-01-22T10:50:42.148796899Z ABC 2020-01-22T10:51:01.840920723Z…