Hi, I am starting workin with influx 2.4 and I made a little scrip with python to upload my data to influx, here is the script:
import influxdb_client
from influxdb_client.client.write_api import SYNCHRONOUS
import time
bucket = "sensor"
org = "karma"
token=the_token
# Store the URL of your InfluxDB instance
url="http://localhost:8086"
client = influxdb_client.InfluxDBClient(
url=url,
token=token,
org=org
)
# Write script
write_api = client.write_api(write_options=SYNCHRONOUS)
temp = 23.0
hum = 40.0
for x in range (10):
p = influxdb_client.Point("dht11").tag("host", "echo").field("temp", temp).field("hum",hum)
temp = temp+float(x)
hum = hum+float(x)
write_api.write(bucket=bucket, org=org, record=p)
time.sleep(5)
And I want to delete some data using influx 1 shell and the next command but it doesn’t work
DROP SERIES FROM “dht11” where “host”=“echo” and “temp”<=30
Error: not implemented: DROP SERIES
I hope someone can help me