The Python sqlite3 module is an SQL interface, this module acts lightweight, self-contained and server less database. SQLite is determined for applications, file-based storage and this is also useful for medium-sized databases.
In this function once the connection is established then we can create a cursor object which acts as a bridge between our python code and the database, this enables the code to execute SQL commands and retrieves data.
List of Python sqlite3 functionsFollowing are the sqlite3 functions, which can be worked with SQLite database from out Python program.
S.No Function & Description 1This API function opens a connection to the SQLite database file. If database is opened successfully, this returns a connection object.
2This creates a cursor which is used for database programming with Python. This function accepts a single optional parameter cursorClass.
3This executes an SQL statements which can be parameterized i.e., placeholders instead of SQL literals.
4This executes the cursor object and it creates an intermediate cursor object by calling the cursor method.
5This function executes an SQL command against all parameter sequences or mappings in the sql sequence.
6This is a shortcut that creates an intermediate cursor object by calling the cursor method with the parameters.
7This function executes the multiple statements in the form of scripts.
8This is the shortcut that creates an intermediate cursor object by calling the cursor method.
9It returns the total number of database rows that have been modified, inserted, or deleted.
10This function returns the current transaction until the last call to commit() is not visible from the other database.
11This function rolls back any changes to the database from the last call to commit().
12This function closes the database connection and doesn't call commit() function to close the database connection.
13This functions fetches the next row of a query that results a single sequence, or None when no more data is available.
14This function fetches the next set of rows of a query that returns a list. A list is returned when no rows are available.
15This function fetches all rows of a query that returns a list.
python_modules.htm
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4