sqlite3-qt


Namesqlite3-qt JSON
Version 0.1.0 PyPI version JSON
download
home_page
SummaryDrop-in Qt-based replacement for the sqlite3 module
upload_time2023-12-16 05:16:52
maintainer
docs_urlNone
author
requires_python>=3.8
licenseGPL-3.0 License
keywords sqlite3 qt
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            .. meta::
   :author: Takeshi Ikuma
   :title: Python SQLite3-Qt - Drop-in replacement for sqlite3 using Qt's QtSql module
   :description: Seemless switching between Python's built-in sqlite3 module with PyQt QtSql module

|pypi| |pypi-status| |pypi-pyvers| |github-license| 

.. 
   |github-status|

.. |pypi| image:: https://img.shields.io/pypi/v/sqlite3-qt
  :alt: PyPI
.. |pypi-status| image:: https://img.shields.io/pypi/status/sqlite3-qt
  :alt: PyPI - Status
.. |pypi-pyvers| image:: https://img.shields.io/pypi/pyversions/sqlite3-qt
  :alt: PyPI - Python Version
.. |github-license| image:: https://img.shields.io/github/license/tikuma-lsuhsc/python-sqlite3-qt
  :alt: GitHub License
.. |github-status| image:: https://img.shields.io/github/workflow/status/python-sqlite3-qt/python-sqlite3-qt/test_n_pub
  :alt: GitHub Workflow Status

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.

.. _Python's sqlite3 built-in module: https://docs.python.org/3/library/sqlite3.html
.. _Qt SQL module: https://doc.qt.io/qt-6/qtsql-index.html

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:

  .. code-block:: python
    
      # 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

.. |QSqlDatabase| replace:: ``QSqlDatabase``
.. |QSqlQuery| replace:: ``QSqlQuery``
.. |PySide2| replace:: ``PySide2``

- Access Qt's QSqlDatabase_ name and QSqlQuery_ objects

  .. code-block:: python

    sqlite3_qt.Connection.qt_name # to get the QSqlDatabase name
    sqlite3_qt.Cursor.qt_query # to access the underlying QSqlQuery object

.. role:: strike
    :class: strike


- Auto-detect ``PyQt6`` / ``PySide6`` / ``PyQt5`` / :strike:`PySide2` (`PySide2` fails the Github CI test)
   
.. _QSqlDatabase: https://doc.qt.io/qt-6/qsqldatabase.html
.. _QSqlQuery: https://doc.qt.io/qt-6/qsqlquery.html
.. _Qt SQLite plugin: https://doc.qt.io/qt-6/sql-driver.html#qsqlite

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.

.. |_| unicode:: 0xA0 
   :trim:

========================================  ============
``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
========================================  ============

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "sqlite3-qt",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "",
    "keywords": "sqlite3,Qt",
    "author": "",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/23/36/24d4c8709067373bf74ae19b3b115438f385b96cf774a9b6bacee9268eb6/sqlite3-qt-0.1.0.tar.gz",
    "platform": null,
    "description": ".. meta::\n   :author: Takeshi Ikuma\n   :title: Python SQLite3-Qt - Drop-in replacement for sqlite3 using Qt's QtSql module\n   :description: Seemless switching between Python's built-in sqlite3 module with PyQt QtSql module\n\n|pypi| |pypi-status| |pypi-pyvers| |github-license| \n\n.. \n   |github-status|\n\n.. |pypi| image:: https://img.shields.io/pypi/v/sqlite3-qt\n  :alt: PyPI\n.. |pypi-status| image:: https://img.shields.io/pypi/status/sqlite3-qt\n  :alt: PyPI - Status\n.. |pypi-pyvers| image:: https://img.shields.io/pypi/pyversions/sqlite3-qt\n  :alt: PyPI - Python Version\n.. |github-license| image:: https://img.shields.io/github/license/tikuma-lsuhsc/python-sqlite3-qt\n  :alt: GitHub License\n.. |github-status| image:: https://img.shields.io/github/workflow/status/python-sqlite3-qt/python-sqlite3-qt/test_n_pub\n  :alt: GitHub Workflow Status\n\nAbout SQLite3-Qt\n~~~~~~~~~~~~~~~~\n\nA drop-in module for `Python's sqlite3 built-in module`_, providing basic \nfunctionality via `Qt SQL module`_. The goal is to enable the creation of a SQL backend module \nwhich can support both script and UI frontends.\n\n.. _Python's sqlite3 built-in module: https://docs.python.org/3/library/sqlite3.html\n.. _Qt SQL module: https://doc.qt.io/qt-6/qtsql-index.html\n\nInstallation\n~~~~~~~~~~~~\n\nInstall using pip::\n\n   pip install sqlite3-qt\n\nFeatures\n~~~~~~~~\n\n- Supports the basic database operations including binding values. (See below for supported ``sqlite3`` classes and functions.)\n\n- API to mimic built-in `sqlite3` module to enable easy swapping:\n\n  .. code-block:: python\n    \n      # import sqlite3              # default import\n      import sqlite3_qt as sqlite3  # drop-in replacement without any change in the code\n\n      ...\n\n- Underlying Qt Database connection name is auto-generated and transparent\n\n.. |QSqlDatabase| replace:: ``QSqlDatabase``\n.. |QSqlQuery| replace:: ``QSqlQuery``\n.. |PySide2| replace:: ``PySide2``\n\n- Access Qt's QSqlDatabase_ name and QSqlQuery_ objects\n\n  .. code-block:: python\n\n    sqlite3_qt.Connection.qt_name # to get the QSqlDatabase name\n    sqlite3_qt.Cursor.qt_query # to access the underlying QSqlQuery object\n\n.. role:: strike\n    :class: strike\n\n\n- Auto-detect ``PyQt6`` / ``PySide6`` / ``PyQt5`` / :strike:`PySide2` (`PySide2` fails the Github CI test)\n   \n.. _QSqlDatabase: https://doc.qt.io/qt-6/qsqldatabase.html\n.. _QSqlQuery: https://doc.qt.io/qt-6/qsqlquery.html\n.. _Qt SQLite plugin: https://doc.qt.io/qt-6/sql-driver.html#qsqlite\n\nCompatibility Table\n~~~~~~~~~~~~~~~~~~~\n\nUnfortunately, not all features of `Python's sqlite3 built-in module`_ can be supported by `Qt SQL module`_. \nThe table below summarizes which ``sqlite3`` functions/classes are currently supported.\n\n.. |_| unicode:: 0xA0 \n   :trim:\n\n========================================  ============\n``sqlite3`` functions and classes         Supported?\n========================================  ============\n``sqlite3.connect(``                      Partially\n|_| |_| ``database,``                     Yes\n|_| |_| ``timeout,``                      Yes\n|_| |_| ``detect_types,``                 No\n|_| |_| ``isolation_level,``              No\n|_| |_| ``check_same_thread,``            No\n|_| |_| ``factory,``                      Yes\n|_| |_| ``cached_statements,``            No\n|_| |_| ``uri,``                          Yes\n|_| |_| ``autocommit)``                   No\n``class sqlite3.Connection``              Yes\n|_| |_| ``cursor()``                      Yes\n|_| |_| ``blobopen()``                    No\n|_| |_| ``commit()``                      Yes \n|_| |_| ``rollback()``                    Yes\n|_| |_| ``close()``                       Yes\n|_| |_| ``execute()``                     Yes\n|_| |_| ``executemany()``                 Yes\n|_| |_| ``executescript()``               Yes\n|_| |_| ``create_function()``             No\n|_| |_| ``create_aggregate()``            No\n|_| |_| ``create_window_function()``      No\n|_| |_| ``create_collation()``            No\n|_| |_| ``interrupt()``                   No\n|_| |_| ``set_authorizer()``              No\n|_| |_| ``set_progress_handler()``        No\n|_| |_| ``set_trace_callback()``          No\n|_| |_| ``enable_load_extension()``       No\n|_| |_| ``load_extension()``              No\n|_| |_| ``iterdump()``                    No\n|_| |_| ``backup()``                      No\n|_| |_| ``getlimit()``                    No\n|_| |_| ``setlimit()``                    No\n|_| |_| ``getconfig()``                   No\n|_| |_| ``setconfig()``                   No\n|_| |_| ``serialize()``                   No\n|_| |_| ``deserialize()``                 No\n|_| |_| ``autocommit``                    ??\n|_| |_| ``in_transaction``                No\n|_| |_| ``isolation_level``               No\n|_| |_| ``row_factory``                   Yes\n|_| |_| ``text_factory``                  Yes\n|_| |_| ``total_changes``                 No\n\n``class sqlite3.Cursor``                  Yes\n|_| |_| ``execute()``                     Yes\n|_| |_| ``executemany()``                 Yes\n|_| |_| ``executescript()``               Yes\n|_| |_| ``fetchone()``                    Yes\n|_| |_| ``fetchmany()``                   Yes\n|_| |_| ``fetchall()``                    Yes\n|_| |_| ``close()``                       Yes\n|_| |_| ``setinputsizes()``               No\n|_| |_| ``setoutputsize()``               No\n|_| |_| ``arraysize``                     Yes\n|_| |_| ``connection``                    Yes\n|_| |_| ``description``                   Yes\n|_| |_| ``lastrowid``                     Yes\n|_| |_| ``rowcount``                      Yes\n|_| |_| ``row_factory``                   Yes\n\n``class sqlite3.Row``                     Yes\n|_| |_| ``keys()``                        Yes\n``class sqlite3.Blob``                    No\n\n``sqlite3.complete_statement()``          No\n``sqlite3.enable_callback_tracebacks()``  No\n``sqlite3.register_adapter()``            No (TODO)\n``sqlite3.register_converter()``          No (TODO)\n``sqlite3.apilevel``                      No\n``sqlite3.paramstyle``                    No\n``sqlite3.sqlite_version``                Yes\n``sqlite3.sqlite_version_info``           Yes\n``sqlite3.threadsafety``                  No\n``sqlite3.version``                       Yes\n``sqlite3.version_info``                  Yes\n========================================  ============\n",
    "bugtrack_url": null,
    "license": "GPL-3.0 License",
    "summary": "Drop-in Qt-based replacement for the sqlite3 module",
    "version": "0.1.0",
    "project_urls": {
        "Repository": "https://github.com/tikuma-lsuhsc/python-sqlite3-qt"
    },
    "split_keywords": [
        "sqlite3",
        "qt"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "443e5e63e1b342a619d13d4b376d20c89b2c4440462759e29fce3e790d3b9af3",
                "md5": "05bd4c8e107cfe9bfec0acfd3520cca2",
                "sha256": "3138caadb93058fa38e9e905f416f90275f3c5430f8eaaa4f00c0b819b965234"
            },
            "downloads": -1,
            "filename": "sqlite3_qt-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "05bd4c8e107cfe9bfec0acfd3520cca2",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 25396,
            "upload_time": "2023-12-16T05:16:50",
            "upload_time_iso_8601": "2023-12-16T05:16:50.717617Z",
            "url": "https://files.pythonhosted.org/packages/44/3e/5e63e1b342a619d13d4b376d20c89b2c4440462759e29fce3e790d3b9af3/sqlite3_qt-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "233624d4c8709067373bf74ae19b3b115438f385b96cf774a9b6bacee9268eb6",
                "md5": "e45f20339d82d098d8440c08be127916",
                "sha256": "eb730882fcf0cff21938243cb2e9b904811bb84fb57d1fb4a443ff4a7e7722e8"
            },
            "downloads": -1,
            "filename": "sqlite3-qt-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "e45f20339d82d098d8440c08be127916",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 27282,
            "upload_time": "2023-12-16T05:16:52",
            "upload_time_iso_8601": "2023-12-16T05:16:52.270188Z",
            "url": "https://files.pythonhosted.org/packages/23/36/24d4c8709067373bf74ae19b3b115438f385b96cf774a9b6bacee9268eb6/sqlite3-qt-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-12-16 05:16:52",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "tikuma-lsuhsc",
    "github_project": "python-sqlite3-qt",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "sqlite3-qt"
}
        
Elapsed time: 2.89372s