You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
508 B
TypeScript
16 lines
508 B
TypeScript
import { open } from 'npm:lmdb';
|
|
import { CsvParseStream } from 'https://deno.land/std@0.184.0/csv/mod.ts';
|
|
|
|
const fileStream = (await Deno.open('/home/brian/Downloads/options-data/2013-01-02options.cvs', {read: true})).readable;
|
|
const csvParseStream = new CsvParseStream({skipFirstRow: true});
|
|
|
|
const rowStream = fileStream
|
|
.pipeThrough(new TextDecoderStream())
|
|
.pipeThrough(csvParseStream)
|
|
;
|
|
const rowReader = rowStream.getReader();
|
|
|
|
|
|
for(let i = 0; i<20; i++){
|
|
console.log(await rowReader.read());
|
|
} |