Skip to main content

PyPI PyPI - Status PyPI - Python Version GitHub License

About SQLite3-Qt

A drop-in module for Python’s sqlite3 built-in module, providing basic functionality via Qt SQL module. The goal is to enable the creation of a SQL backend module which can support both script and UI frontends.

Installation

Install using pip:

pip install sqlite3-qt

Features

  • Supports the basic database operations including binding values. (See below for supported sqlite3 classes and functions.)

  • API to mimic built-in sqlite3 module to enable easy swapping:

    # import sqlite3              # default import
    import sqlite3_qt as sqlite3  # drop-in replacement without any change in the code
    
    ...
  • Underlying Qt Database connection name is auto-generated and transparent

  • Access Qt’s QSqlDatabase name and QSqlQuery objects

    sqlite3_qt.Connection.qt_name # to get the QSqlDatabase name
    sqlite3_qt.Cursor.qt_query # to access the underlying QSqlQuery object
  • Auto-detect PyQt6 / PySide6 / PyQt5 / PySide2 (PySide2 fails the Github CI test)

Compatibility Table

Unfortunately, not all features of Python’s sqlite3 built-in module can be supported by Qt SQL module. The table below summarizes which sqlite3 functions/classes are currently supported.

sqlite3 functions and classes

Supported?

sqlite3.connect(

Partially

  database,

Yes

  timeout,

Yes

  detect_types,

No

  isolation_level,

No

  check_same_thread,

No

  factory,

Yes

  cached_statements,

No

  uri,

Yes

  autocommit)

No

class sqlite3.Connection

Yes

  cursor()

Yes

  blobopen()

No

  commit()

Yes

  rollback()

Yes

  close()

Yes

  execute()

Yes

  executemany()

Yes

  executescript()

Yes

  create_function()

No

  create_aggregate()

No

  create_window_function()

No

  create_collation()

No

  interrupt()

No

  set_authorizer()

No

  set_progress_handler()

No

  set_trace_callback()

No

  enable_load_extension()

No

  load_extension()

No

  iterdump()

No

  backup()

No

  getlimit()

No

  setlimit()

No

  getconfig()

No

  setconfig()

No

  serialize()

No

  deserialize()

No

  autocommit

??

  in_transaction

No

  isolation_level

No

  row_factory

Yes

  text_factory

Yes

  total_changes

No

class sqlite3.Cursor

Yes

  execute()

Yes

  executemany()

Yes

  executescript()

Yes

  fetchone()

Yes

  fetchmany()

Yes

  fetchall()

Yes

  close()

Yes

  setinputsizes()

No

  setoutputsize()

No

  arraysize

Yes

  connection

Yes

  description

Yes

  lastrowid

Yes

  rowcount

Yes

  row_factory

Yes

class sqlite3.Row

Yes

  keys()

Yes

class sqlite3.Blob

No

sqlite3.complete_statement()

No

sqlite3.enable_callback_tracebacks()

No

sqlite3.register_adapter()

No (TODO)

sqlite3.register_converter()

No (TODO)

sqlite3.apilevel

No

sqlite3.paramstyle

No

sqlite3.sqlite_version

Yes

sqlite3.sqlite_version_info

Yes

sqlite3.threadsafety

No

sqlite3.version

Yes

sqlite3.version_info

Yes

Metadata

Release files for sqlite3-qt 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sqlite3-qt 0.1.0
File Size Uploaded Provenance
sqlite3-qt-0.1.0.tar.gz 27.3 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for sqlite3-qt 0.1.0
File Interpreter ABI Platform
sqlite3_qt-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 52.7 kB

Release files / sqlite3-qt-0.1.0.tar.gz

Download URL sqlite3-qt-0.1.0.tar.gz
Size 27.3 kB
Tags Source
SHA-256 checksum
How to use checksums
eb730882fcf0cff21938243cb2e9b904811bb84fb57d1fb4a443ff4a7e7722e8
BLAKE2b-256 checksum
How to use checksums
233624d4c8709067373bf74ae19b3b115438f385b96cf774a9b6bacee9268eb6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/4.0.2 CPython/3.11.7

Release files / sqlite3_qt-0.1.0-py3-none-any.whl

Download URL sqlite3_qt-0.1.0-py3-none-any.whl
Size 25.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3138caadb93058fa38e9e905f416f90275f3c5430f8eaaa4f00c0b819b965234
BLAKE2b-256 checksum
How to use checksums
443e5e63e1b342a619d13d4b376d20c89b2c4440462759e29fce3e790d3b9af3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/4.0.2 CPython/3.11.7

Security for sqlite3-qt 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page