I’m creating an application using python and sqllite3. Are the users required to install sqllite manually?
How do I create the tables and do initialization while installing?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The sqlite3 module is part of the python standard library and shipped with python itself. Having sqlite installed is a requirement, but (at least on linux) package managers take care of installing sqlite (I can’t say anything about windows here).
You can create your tables on the first run of your application. To make sure you’re not trying to create them twice, use
CREATE TABLE IF NOT EXISTS ...(cf. the docs) which will only create the table if it doesn’t already exist.