Convert "true" & "false" values to "1" and "0" in influxdb

Hello All,

Can you all please help me map or convert “true” and “false” influxdb values to 1 & 0.
I would like if this conversion is possible with query.

Thanks in advance
Lochana