Skip to main content

Aiohttp web service for querying several databases easily

Project description

QuerySource

QuerySource is a powerful Python library designed to streamline access to multiple databases and external APIs through a single, unified interface. Utilizing the proxy design pattern, QuerySource allows developers to seamlessly integrate various data sources into their projects without worrying about the complexities of managing multiple connections.

Features

  • Unified interface for querying multiple databases (Redis, PostgreSQL, MySQL, Oracle, SQL Server, InfluxDB, CouchDB, Druid)
  • Support for external APIs (Salesforce, ShopperTrack, ZipCodeAPI, etc.)
  • Easy-to-use API for executing queries
  • Extensible design, allowing for easy addition of new data sources

Installation

$ pip install querysource
---> 100%
Successfully installed querysource

Requirements

Basic Usage

QuerySource can be used in several ways, one is using QS object itself:

from querysource.queries.qs import QS

query = QS(
    query='SELECT * FROM tests',
    output_format='pandas'
)
result, error = await query.query()

Extending QuerySource

To add support for a new data source, create a new class inheriting from the BaseProvider or BaseAPI class and implement the required methods (prepare_connection, query, close). Then, register the new data source in the QuerySource class by adding it to the appropriate dictionary (_supported_databases or _supported_apis).

Contributing

We welcome contributions to QuerySource! If you'd like to contribute, please follow these steps:

  • Fork the repository
  • Create a new branch for your feature or bugfix
  • Implement your changes
  • Add tests covering your changes
  • Create a pull request against the original repository

Contribution guidelines

  • Writing tests
  • Code review
  • Other guidelines

License

QuerySource is released under the BSD License. See the LICENSE file for more details.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

querysource-4.1.10.tar.gz (2.8 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

querysource-4.1.10-cp313-cp313-musllinux_1_2_x86_64.whl (13.4 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.1.10-cp313-cp313-manylinux_2_28_x86_64.whl (13.3 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

querysource-4.1.10-cp312-cp312-musllinux_1_2_x86_64.whl (13.4 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.1.10-cp312-cp312-manylinux_2_28_x86_64.whl (13.4 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

querysource-4.1.10-cp311-cp311-musllinux_1_2_x86_64.whl (13.2 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.1.10-cp311-cp311-manylinux_2_28_x86_64.whl (13.1 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

querysource-4.1.10-cp310-cp310-musllinux_1_2_x86_64.whl (12.4 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.1.10-cp310-cp310-manylinux_2_28_x86_64.whl (12.3 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

File details

Details for the file querysource-4.1.10.tar.gz.

File metadata

  • Download URL: querysource-4.1.10.tar.gz
  • Upload date:
  • Size: 2.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for querysource-4.1.10.tar.gz
Algorithm Hash digest
SHA256 1c3011daa0126a0b677f23f8ace6ab497d9fbc16ad254859fcf46ae9de0e5f3f
MD5 82e5c380388772b5ed5775592ed2b032
BLAKE2b-256 c1c72b416109dde109dbccf463a0ea1408ce0d6e4c5e0250016be41580e73550

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp313-cp313-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 e73c1ecb56ecc352bcce59fd345c5b331edb6a7a77ee3184415ff4a13decc053
MD5 37bb4558e98b8b60bccabb04b8838ed1
BLAKE2b-256 dbe15f1a14a00d3ea8b12d87c38993dd98a19cf580c1c364277c789c400c2e04

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b68d55cd6d69c4307db6e37a8d1b6010874af08af75e9c06647bf797a47df734
MD5 ec2f5786a692c52946ef3331d6538f3e
BLAKE2b-256 0bca443322f777e59cd7680d744ae2278448dd291b8cc370e718d6ff36ac2afb

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 cf3c0aec7ec5e9f374c8e6a347d54fee1e5e9d5023254dcb1a290b75fd172e9d
MD5 c8e92e2899440dc1cf22561744f9a933
BLAKE2b-256 b93cdb3a8942611b1a1667401f8d8a72d6474e261c44a61158330492303c1ebd

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5a70a2ebd77bdd2cc4e9f7135038d7d6a32809c1117c408fbdf81df8c49ee9a3
MD5 028c8935904781337f9585b034409ebf
BLAKE2b-256 d7fb816f20e213a709fd41a26aa8459f507082d6544463efc336838d2dbb953e

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 488f01842d57877c68fcfb4e01eafe9b037f38b59cc5a0499c03881e949d0f98
MD5 75932ed09c472d8c044a267db897734e
BLAKE2b-256 5a86097cad1abe47bbe75a54efc5225b59526ed472ed7ab1062edef31d2c301e

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 a419b78f24847060340ab8aa700b7f369127f31ddab2c23fd8c53326fd9a4c76
MD5 9bd61428b526bd771ca91ff18a4b425d
BLAKE2b-256 46795c413d526f0eb408d1659ae72845fd04b1f07fdd89c0cd9a892d18df2188

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 eba8e998512798c6c79e29e085f2716aa4d36cf5f9fee861d08e0d1c88f3a253
MD5 4bdebc46786347cd130ca8fed6e4a8cf
BLAKE2b-256 18d9e3df765ec6c465a9f6293880260589e452e165f60c395849d24280db8c52

See more details on using hashes here.

File details

Details for the file querysource-4.1.10-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.1.10-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 6b08d9dfe5cf2943aaf239e5d414577f9a67fdf86d9099bdc6646d03ec77603c
MD5 2541fa9ca2a2e1edd04cc596cf33bbb2
BLAKE2b-256 3c1a21d56d42d95d05961d10f29201214682fb771667dfd7efb1029132fb26ee

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page