I decided myself using csv-stream module
Here is a snippset
var options = {
delimiter : ';',
endLine : '\n',
columns : ['VERSION_ID', 'TN','RN1','DATA','OPERACAO','CNL','EOT'],
columnOffset : 7,
escapeChar : '"',
enclosedChar : '"'
}
var csvStream = csv.createStream(options);
i = 0
request('http://yourhugefile.csv').pipe(csvStream)
.on('error',function(err){
console.error(err);
})
.on('data',function(data){
})
.on('column',function(key,value){
if(key == 'TN' || key == 'RN1')
firebaseUpload(value);
})
source
share