Cannot query data for specific time range

InfluxDB does not return data for specific time range. For example, when I query using Data Explorer for the past 7d, the data is shown. But when I select the past 30d, Data Explorer shows “No Results”. Can anyone help?

Hi @clitetailor,
That is extremely interesting. What version of InfluxDB 2 OSS are you running? If you press the refresh dial next to the past 30 days do you get the same result?

If you click script editor and change the following:

|> range(start: v.timeRangeStart, stop: v.timeRangeStop)


|> range(start: -30d)

Do you get the same result?

Yes, the same result goes with the script editor. I use range(start: -7d) and range(start: -30d) also. Using range(start: -7d) would return records but range(start: -30d) not.

I suspect that there was some issue with datatype. I have inserted items before 2021-12-26 as integer datatype and insert other items after 2021-12-26 as float datatype. When I insert new float value using line protocol for data between 2021-12-22 to 2021-12-26, it returns error:

    "code": "unprocessable entity",
    "message": "failure writing points to database: partial write: field type conflict: input field \"distance\" on measurement \"performance\" is type float, already exists as type integer dropped=1"

But when I insert new value after 2021-12-26 as float, it seems to be okey. I tried to delete all the data with integer datatype but it still not work. Do you know how to delete all the partition with wrong datatype in InfluxDB?