I have to log 5 data together in different column,
I write this query but it give "ER_PARSE_ERROR" please help.
var co = { payload: msg.payload[0]};
var ox = { payload: msg.payload[1]};
var lux = { payload: msg.payload[3]};
var temp = { payload: msg.payload[2]};
msg.topic = 'INSERT INTOnode-red
.final
(CO
,OX
,Lux
,Temp
) VALUES (' + co + ',' + ox + ',' + lux + ',' + temp + ')';
return msg;
I get data in this form whic i have to log in to my sql.
array[5]
0: "4"
1: "000"
2: "000"
3: "0032"
4: "00"