influxdata / influxdata/influxdb
Group query exception error
- Dominant language
- Rust
- Stars
- 31.7k
- Forks
- 3.7k
- Avg merge
- 13h 37m
- Merged PRs (30d)
- 8
Description
## version 2.0.3
## flux:
```
from(bucket: "zm")
|> range(start: 2021-01-07T22:00:00Z,stop: 2021-01-08T10:00:00Z)
|> filter(fn: (r) => r["_measurement"] == "jzVoPP7mJP-jzzAAeDF9wiU8wrwM9")
|> group(columns: ["_time"], mode: "by")
|> sort(columns: ["_time"],desc:true)
```
## java error:
```
com.influxdb.exceptions.BadRequestException: runtime error @3:82-3:119: group: schema collision detected: column "_value" is both of type bool and float
at com.influxdb.internal.AbstractRestClient.responseToError(AbstractRestClient.java:96)
at com.influxdb.internal.AbstractQueryApi$1.onResponse(AbstractQueryApi.java:145)
at com.influxdb.internal.AbstractQueryApi.query(AbstractQueryApi.java:193)
at com.influxdb.internal.AbstractQueryApi.query(AbstractQueryApi.java:104)
at com.influxdb.client.internal.QueryApiImpl.query(QueryApiImpl.java:803)
at com.influxdb.client.internal.QueryApiImpl.query(QueryApiImpl.java:105)
at com.influxdb.client.internal.QueryApiImpl.query(QueryApiImpl.java:83)
at com.influxdb.client.internal.QueryApiImpl.query(QueryApiImpl.java:73)
```
## web
```
runtime error @4:6-4:43: group: schema collision detected: column "_value" is both of type bool and float
```
**A row of data at the same time point has multiple _fields, and their types are boolean and floating point types, which makes it impossible to use the group function**
Contributor guide
Research direction
Start by reproducing the reported Flux query on InfluxDB 2.0.3 with boolean and floating-point fields sharing a timestamp, then inspect how group handles the resulting _value schema collision. Done should establish whether this is expected behavior or identify a fix and regression coverage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100