hello guys i m new over here and got confuse how i can use readstream and write stream right now i tried this(i m using this library https://www.npmjs.com/package/csv-parse)
fs.createReadStream(path.join(__dirname,"../demofile/Customers.csv"))
.pipe(parse(options))
.on('data', function(csvrow) {
console.log(csvrow);
//do something with csvrow
output.push(csvrow);
})
.on('end',function() {
//do something wiht csvData
console.log(csvData);
});
but i don't think it correct way read and write stream of csv-parse can anyone suggest me how i can use read and write with above code. basically i want to read a csv file and write it into another csv file reason for using read and write stream is because my file size is about 2gb