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.6.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.6-cp313-cp313-musllinux_1_2_x86_64.whl (12.3 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.1.6-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.3 MB view details)

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

querysource-4.1.6-cp312-cp312-musllinux_1_2_x86_64.whl (12.3 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.1.6-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.4 MB view details)

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

querysource-4.1.6-cp311-cp311-musllinux_1_2_x86_64.whl (12.1 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.1.6-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.1 MB view details)

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

querysource-4.1.6-cp310-cp310-musllinux_1_2_x86_64.whl (11.3 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.1.6-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (11.3 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.1.6.tar.gz.

File metadata

  • Download URL: querysource-4.1.6.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.6.tar.gz
Algorithm Hash digest
SHA256 1809c23813548e89b41bdb785ccd9ea2160fde2d2bd3a738b1e8c5d8c188ee87
MD5 9f208be7ebb2befd98c7dae4b5569b19
BLAKE2b-256 b02c3eaf559c62a31838d65c58ac65484fe429bcc917ca4fae850c7da20d47f8

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 894d72c4a9769da3deaa2c5cb180a879850a330768ef54c95ead273fc993db6b
MD5 1103e57885b3457091337deb3edeb641
BLAKE2b-256 fae177ccd5ab04160773d5bb5f64df1da1528295d3203bb3e4501a709bf10dca

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 0e09333f4535734f521c53cbba50a7b2813b4d06eb3c5d0a135e4dbef3a468c5
MD5 3c502a5bbc835453fc160c8596b69e5e
BLAKE2b-256 9ce8afa10f0af5f7827f3c6ec0c008008f5cceea2ebc22e0f219eb2927adebd1

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 3fd6d91c98a1fc987dd075acaf9ff24a67fde00d76c81008982bb10db76252b6
MD5 501fc195c7bbd7e914ef21c6a3f46c08
BLAKE2b-256 f2a9ddf83ea1158d9d51ececbed9e82e5ba70651691e734afdee86fc6184acdd

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 fb51f90a31f035c67f06c2cdcb7dfdf1508d857f0fe92cb11c7de18d76ff4c83
MD5 57471ede154aa1af641b7e75795cebe8
BLAKE2b-256 933191af3458f78f364d3c102e29e7b8832634b1075fb45f0975e7258f43d4d9

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 7f050df349a9a091e074d462e312fd3439e3b549d3e09e84922cf832a7bf76c8
MD5 2b3679e76f7d934334752400c2bd0ed7
BLAKE2b-256 344d5c07da44c53438caac92c939a3bc7915cb5d3c2dbf6b87e63e1479112113

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 81d8c68079d331418faa764d4fb0b77f0ccf46feb9550d56506a88ced55d6db6
MD5 2bc96f9d15ae83ccefbb40ecad3a87ae
BLAKE2b-256 e5db784ad19786fa94a828fd59ea50b80bbc57b4e19cbdf89e63322396ffafe2

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 a2def48fdb62cc898ea30e93765767011713e592ee2f23a4bee721937d65ef08
MD5 02a938c93dfb6b6a90b8f8300434bb1e
BLAKE2b-256 a3c23812ea36d88799a4b58abe0cb2cb27ce7b269d48cbc3caa1d461745ac4c0

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.6-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 f1c8248aa91f9af81f257a451362c42a77556792010fddfecae6c9196af4ec4e
MD5 0b831f895a4cabec49def1c4ac3f1be2
BLAKE2b-256 15be2ba156cd9941de45c253b0f24f977aa96a9e837663d29ccb0a7fc5a69fb5

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