Importing CSV file into SQLite using sql.js Importing CSV file into SQLite using sql.js database database

Importing CSV file into SQLite using sql.js


I was wondering if it's possible to import the CSV via javascript

Yes it is possible, csv is just data, and sqlite is a database, so yes you can put data in to the database.

You just need to figure out how you want to store the data first, then read the csv data, format it accordingly, and save it to your sqlite db.

There are a number of javascript libraries for reading csv data on npm.


Yes it possible. If you are using nodejs then install the npm csv Package and install the package.
then just require the package in you program and save the csv file data according to you requirement.

npm csv

It can handle the large data.