InfluxQL not giving the expected result (querying InfluxDB through shell)

SELECT value, codeDevice FROM myMeasurement
gives at least these results :
┏━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━┓
┃ index ┃ time ┃ value ┃ codeDevice ┃
┣━━━━━━━╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╋━━━━━━━━━━━━━━━━━╋━━━━━━━━━━┫
┃ 1┃ 1702162800000000000.0000000000┃ 0.0000000000┃ACT01TC4 ┃
┃ 2┃ 1702162800000000000.0000000000┃ 0.0000000000┃ACT01TC4 ┃
┃ 3┃ 1702162800000000000.0000000000┃ 0.0000000000┃ACT10TC2 ┃
┃ 4┃ 1702162800000000000.0000000000┃ 0.0000000000┃ACT10TC2 ┃

Now, when I introduce a filter on codeDevice, it gives no result :
SELECT value, codeDevice FROM myMeasurement WHERE codeDevice = ACT01TC4
No results

Can someone pls explain this mystery ?

Hi,

Try with single quotes for codedevice as shown below.

SELECT value, codeDevice FROM myMeasurement WHERE codeDevice = ‘ACT01TC4’

it will work

ok, thank you, I had tried “double quote” with no success.

Hi,

Try with single quote it will work

Sure, that’s why I marked your answer as “solution”, otherwise I wouldn’t :wink:

Is it possible to query InfluxDB 2, not with shell, but through Script Editor with this InfluxQL query ?

Hi,

it will work thru script editor