diff --git a/server.js b/server.js index 3a71643..0cd8853 100644 --- a/server.js +++ b/server.js @@ -143,9 +143,9 @@ app.post('/csv', (req, res, next) => { var _cnt = 0; const path = '/var/www/html/appexe/natnats/23/bin/mobileweb2/resources/database/user_record.csv'; if (fs.existsSync(path)) { - // fs.createReadStream(path) - // .pipe(parse({ delimiter: ",", from_line: 1 })) - // .on("data", function (row) { + fs.createReadStream(path) + .pipe(parse({ delimiter: ",", from_line: 1 })) + .on("data", function (row) { // _cnt += 1; // if(_cnt == 1){return;} // console.log("--- r-0 ----", row[0]); @@ -166,7 +166,7 @@ app.post('/csv', (req, res, next) => { // } res.send({'id': _res}); - //}); + }); // if(_res === ""){ // writetoFile(csv); // _res = _jsessionid;