pysqliteDB-API 2.0 interface for SQLite databases | |
Download |
pysqlite Ranking & Summary
Advertisement
pysqlite Tags
pysqlite Description
pysqlite was written to provide a SQL interface compliant with the DB-API 2.0 specification. SQLite is a C library that provides a lightweight disk-based database that doesn’t require a separate server process and allows accessing the database using a nonstandard variant of the SQL query language. Some applications can use SQLite for internal data storage. It’s also possible to prototype an application using SQLite and then port the code to a larger database such as PostgreSQL or Oracle. To use the pysqlite module, you must first create a Connection object that represents the database. Usually your SQL operations will need to use values from Python variables. You shouldn’t assemble your query using Python’s string operations because doing so is insecure; it makes your program vulnerable to an SQL injection attack. Instead, use the DB-API’s parameter substitution. Put ? as a placeholder wherever you want to use a value, and then provide a tuple of values as the second argument to the cursor’s execute() method. That's about it!
pysqlite Related Software