Hello!
I have a user of my android app that reported problems when updating fields.
I’m using influxdb-client-java:6.4.0.
The query is for example like this:
from(bucket: “HC3”) |> range(start: 1686295275, stop: 1686295997) |> filter(fn: (r) => r.deviceID == “224” and r.unit == “°C” and r._field == “value” or r.deviceID == “228” and r.unit == “°C” and r._field == “value” or r.deviceID == “180” and r.unit == “°C” and r._field == “value”)
Then the response:
com.influxdb.exceptions.BadRequestException: HTTP status code: 400; Message: Error creating series plans for namespace ‘32d1e4fdd1bd42ea_8680e907b5fce791’: read_filter: gRPC planner got error creating predicates: Error during planning: Unsupported _field predicate: CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“224”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”) OR CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“228”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”) OR CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“180”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”)
caused by
Error during planning: Unsupported _field predicate: CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“224”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”) OR CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“228”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”) OR CASE WHEN deviceID IS NULL THEN Utf8(“”) ELSE deviceID END = Utf8(“180”) AND CASE WHEN unit IS NULL THEN Utf8(“”) ELSE unit END = Utf8(“°C”) AND _field = Utf8(“value”)
When querying a single field it works fine from his database.
Could anybody point me in the right direction?
Thanks!
Magnus