If condition is true select the specfic record

we connect IOT device with MQTT by node-red and push this data into MSSQL.
what we won't put condition when the x tag value = ON then select only specific data.

we achieve this in the MSSQL query but we want to do in node-red. in the picture, we can select the highlighted data through SQL query. can we do it same in Node-red?

Hi @alikhan could you perhaps provide a bit more detail or clarify your requirement? It is not very clear what you are trying to do.

Perhaps a step by step description?