How to use QML to import a CSV to s SQLite database? -
i've been programming app uses 2 databases, 1 of contains contacts i've exported outlook.
i import these sqlite database using qml/javascript only.
i have created table , i'm trying execute below commands:
function createtable(database) { database.transaction( function(tx) { tx.executesql('create table if not exists staff(id integer primary key autoincrement, "first name" text, "last name" text)'); tx.executesql('.mode csv'); tx.executesql('".import" "./contacts.csv"'); } ) } i haven't got .import yet secondary. i'm guessing must missing method i'm not familiar with.
any appreciated.
Comments
Post a Comment