Try this...
[{"id":"5b494e09.c29e5","type":"function","z":"b8d87de8.2e416","name":"","func":"msg.payload[0] = msg.payload[0].replace(/[\\u{0000}-\\u{0003}]/gu,\"\");\nmsg.topic = \"SELECT `Pleats` FROM `pleatco` WHERE Part_Number = ?\";\nreturn msg;\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":700,"y":200,"wires":[["afda14e9.6cf2b8"]]},{"id":"4987d1a5.1256b","type":"inject","z":"b8d87de8.2e416","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"[\"PWW10\"]","payloadType":"json","x":540,"y":240,"wires":[["5b494e09.c29e5"]]},{"id":"afda14e9.6cf2b8","type":"debug","z":"b8d87de8.2e416","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":870,"y":200,"wires":[]},{"id":"f3b592d4.57f68","type":"buffer-parser","z":"b8d87de8.2e416","name":"","data":"responseBuffer.buffer","dataType":"msg","specification":"spec","specificationType":"ui","items":[{"type":"ascii","name":"item1","offset":0,"length":-1,"offsetbit":0,"scale":"1","mask":""}],"swap1":"swap16","swap2":"","swap3":"swap16","swap1Type":"swap","swap2Type":"swap","swap3Type":"swap","msgProperty":"payload","msgPropertyType":"str","resultType":"value","resultTypeType":"output","multipleResult":false,"fanOutMultipleResult":false,"setTopic":true,"outputs":1,"x":530,"y":200,"wires":[["5b494e09.c29e5"]]},{"id":"e42a451b.0778c8","type":"function","z":"b8d87de8.2e416","name":"test data 1 PWW10","func":"return {\n \"_msgid\":\"d1bf9110.d196d\",\n \"payload\":[22352,12631,48,0,0,0,0,0,0,0],\n \"topic\":\"886f87b5.5a0bb8\",\n \"messageId\":\"60b1288c36ee442146f90792\",\n \"modbusRequest\":{\"unitid\":1,\"fc\":3,\"address\":36866,\"quantity\":10,\"emptyMsgOnFail\":true,\"keepMsgProperties\":true,\"messageId\":\"60b1288c36ee442146f90792\"},\n \"responseBuffer\":{\n \"data\":[22352,12631,48,0,0,0,0,0,0,0],\n \"buffer\":Buffer.from([87,80,49,87,0,48,0,0,0,0,0,0,0,0,0,0,0,0,0,0])\n }\n}\n ","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":290,"y":100,"wires":[["f3b592d4.57f68"]]},{"id":"e2f99c6c.d1208","type":"inject","z":"b8d87de8.2e416","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":120,"y":100,"wires":[["e42a451b.0778c8"]]},{"id":"162569d7.e92c26","type":"function","z":"b8d87de8.2e416","name":"test data 1 PWW100","func":"return {\n \"_msgid\":\"d1bf9110.d196d\",\n \"payload\":[22352,12631,48,0,0,0,0,0,0,0],\n \"topic\":\"886f87b5.5a0bb8\",\n \"messageId\":\"60b1288c36ee442146f90792\",\n \"modbusRequest\":{\"unitid\":1,\"fc\":3,\"address\":36866,\"quantity\":10,\"emptyMsgOnFail\":true,\"keepMsgProperties\":true,\"messageId\":\"60b1288c36ee442146f90792\"},\n \"responseBuffer\":{\n \"data\":[22352,12631,48,0,0,0,0,0,0,0],\n \"buffer\":Buffer.from([87,80,49,87,0,48,0,48,0,0,0,0,0,0,0,0,0,0,0,0])\n }\n}\n ","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":300,"y":140,"wires":[["f3b592d4.57f68"]]},{"id":"92503463.70b918","type":"inject","z":"b8d87de8.2e416","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":120,"y":140,"wires":[["162569d7.e92c26"]]},{"id":"d831086f.41a548","type":"inject","z":"b8d87de8.2e416","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":120,"y":180,"wires":[["bca0c39a.d26c5"]]},{"id":"bca0c39a.d26c5","type":"function","z":"b8d87de8.2e416","name":"test data 1 PWW1111","func":"return {\n \"_msgid\":\"d1bf9110.d196d\",\n \"payload\":[22352,12631,48,0,0,0,0,0,0,0],\n \"topic\":\"886f87b5.5a0bb8\",\n \"messageId\":\"60b1288c36ee442146f90792\",\n \"modbusRequest\":{\"unitid\":1,\"fc\":3,\"address\":36866,\"quantity\":10,\"emptyMsgOnFail\":true,\"keepMsgProperties\":true,\"messageId\":\"60b1288c36ee442146f90792\"},\n \"responseBuffer\":{\n \"data\":[22352,12631,48,0,0,0,0,0,0,0],\n \"buffer\":Buffer.from([87,80,49,87,0,49,0,49,0,49,0,0,0,0,0,0,0,0,0,0])\n }\n}\n ","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":300,"y":180,"wires":[["f3b592d4.57f68"]]}]
NOTE:
I changed your query to use prepared statement (safer than building a string query) but if it doesnt work with your database, change it back to
msg.topic = "SELECT `Pleats` FROM `pleatco` WHERE Part_Number = `" + msg.payload[0] + "`";`