CSV import fixed

This commit is contained in:
Jan Prochazka
2024-09-17 09:59:47 +02:00
parent 319a7fd003
commit 4065e05013
4 changed files with 49 additions and 32 deletions

View File

@@ -51,6 +51,7 @@ async function reader({ fileName, encoding = 'utf-8', header = true, delimiter,
delimiter,
skip_lines_with_error: true,
to_line: limitRows ? limitRows + 1 : undefined,
ltrim: true,
});
const downloadedFile = await dbgateApi.download(fileName);
const fileStream = fs.createReadStream(downloadedFile, encoding);