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

This version

4.0.1

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.0.1.tar.gz (2.6 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.0.1-cp313-cp313-musllinux_1_2_x86_64.whl (12.0 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.0.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.1 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

querysource-4.0.1-cp312-cp312-musllinux_1_2_x86_64.whl (12.0 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.2 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

querysource-4.0.1-cp311-cp311-musllinux_1_2_x86_64.whl (11.9 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (11.9 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

querysource-4.0.1-cp310-cp310-musllinux_1_2_x86_64.whl (11.1 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (11.1 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

File details

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

File metadata

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

File hashes

Hashes for querysource-4.0.1.tar.gz
Algorithm Hash digest
SHA256 f671925526c2f8732c02fc9a3e29da18e0459226d7aa3e9ebe4373012af9ad07
MD5 de03ff9cf2e9216ea18a1ec1b65053ed
BLAKE2b-256 095ef7ee5510858e32fec8849142c0b56b4fa8aee044101035751d5b3f5e3720

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.0.1-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 41a91d5d96cf64e224ca3d8c4ac87664310ddb23357300f93db60df2f38cf339
MD5 f756f1af2cd98520e90b662517a7230e
BLAKE2b-256 a80b00081825b341f379bed327efd6b30d6efdae97adf53df6c48ea3c69094d3

See more details on using hashes here.

File details

Details for the file querysource-4.0.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.0.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5a72fe29ed2d6d69179237481f7d2dce2ee6f6bd7d78cec7643414e20fde5d72
MD5 2e346ae864a1fbaa520971b069a851b4
BLAKE2b-256 d7e6182614847a312f85f45200f640b4d1bf93597cd862a13fd0e5b12324aaf6

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.0.1-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 298e6ceb452e660b23159b8164deeeb687e29796d926964f257d5e3e16351706
MD5 e0d8efd6b6507241be45d0118e974d70
BLAKE2b-256 e4dd59c43214e348bd614363dd7e62c9015d26b19b32c73b92589fce5ca34c7c

See more details on using hashes here.

File details

Details for the file querysource-4.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ef37ccf76a3567caf6ea5b57224c4fca42dbf321100f615b94420ea3d94c44e5
MD5 4bbdcb53fd1f2fb89ef4ac9da9f972bb
BLAKE2b-256 7cbc43087c286bd71c97d64f8601b780bc4bd0371e8c724297982bb3784cd118

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.0.1-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 b22d96fb954716a1acf4609840612097d5d2bb15d71b9b9f1ad87de02d7f2ca4
MD5 cfc209a0f6399f8bad6272dec02decc4
BLAKE2b-256 605daa0bd4ae28987ec95045d6b1fecf3adcb59b82470b19676bf6e101af3011

See more details on using hashes here.

File details

Details for the file querysource-4.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 a73a2c30c126cfb14e32928a7ed98750c9392af8c9934fa8b7ed10f0e6b3d714
MD5 c1c44a2bf0c06689ead5ecc9afd4ff1b
BLAKE2b-256 2eb1292894ae15573d57995748d1c0da8039faabb1f2e743f3ddf9e831dab2b7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.0.1-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 df6f436c669d64d2dae8ad52a917eee6cb82bc45264c718b6838cf21285a5f3d
MD5 6403b3f5b9eab04aacb1260de74c9086
BLAKE2b-256 f6c7322e1eba6101fadec14b40c07a9ed78259ee077fcd6a67f41c478928f7bf

See more details on using hashes here.

File details

Details for the file querysource-4.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for querysource-4.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 2ad009cd78296ab77db66fc44993d0a0375b54ea505e7be9104f6066f4afee64
MD5 9bb14a613e39fb08ccf0bdbda247c05b
BLAKE2b-256 c14df2a622dba7ae8334cf28215d1cdc21c541def644e0368324b33d2c1ac1b7

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