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.1.3

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.3.tar.gz (4.7 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.3-cp313-cp313-musllinux_1_2_x86_64.whl (15.2 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.1.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (15.3 MB view details)

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

querysource-4.1.3-cp312-cp312-musllinux_1_2_x86_64.whl (15.3 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.1.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (15.3 MB view details)

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

querysource-4.1.3-cp311-cp311-musllinux_1_2_x86_64.whl (15.1 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.1.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (15.1 MB view details)

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

querysource-4.1.3-cp310-cp310-musllinux_1_2_x86_64.whl (14.2 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.1.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (14.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.3.tar.gz.

File metadata

  • Download URL: querysource-4.1.3.tar.gz
  • Upload date:
  • Size: 4.7 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.3.tar.gz
Algorithm Hash digest
SHA256 1ef188147af2c91cc5fbefc6d3d66bf5c463c677834dcded1726c6f16d7be417
MD5 79f974286a6b6b0d5bc0e3b79cb18f01
BLAKE2b-256 edfb1fceda8e6c6e9fd2b12e7be664596f8a987f1e9bf4da4c0348077baaae0e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.3-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 ea773fe26befc3ddd27143a1cf7cf3babba70e23d9c7b4cd3d69b1ef4fa384fd
MD5 49b4a6c7d6286708f4f5c2df2f935d12
BLAKE2b-256 3904bc89695a2496d143881325da4252e1c060b2500aef461e66fc2b1d1e1b1f

See more details on using hashes here.

File details

Details for the file querysource-4.1.3-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.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 e6f72d8ec7c1d88470ac3b9b6f0f3139a39a3812d668eb3b491ec9e495f4a1a8
MD5 71b1ed1a058d3d09c87ab24b176570b5
BLAKE2b-256 f5af6b23c08e54969eae2cc13b57350934192b6c317e4901f8eb9b909c89f5bb

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.3-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 85a7774dcd24c59504f3f943ff41ed96db388d877e995e3372a37257748b148f
MD5 cfae72d19291aaa234dab25629258833
BLAKE2b-256 cfd60186cd363678dfbf295c0ec17d4596645a57899c76e6849ff8d0fb74ae88

See more details on using hashes here.

File details

Details for the file querysource-4.1.3-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.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 311d05f9044f08fa67e8661b579cbd3437dfaa743a74be87608b1f0968c3d8a3
MD5 46f799fafcd2fd238a3da2d301e0d78e
BLAKE2b-256 412e51edc80aa7bfd2e8bcdf7a785d145406d2b01658d7b5646823e67f20b115

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.3-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 324e97dbe0262fd3789ff0177740c6e21d3cbaea6cd3ef195368ecfa7e7a3b96
MD5 6ab7785dc00b8c3578ebaec2e5653d17
BLAKE2b-256 c899de85fed808b2250ed1996f35936bf777a5e92331cd6cfa4b3728c3e15512

See more details on using hashes here.

File details

Details for the file querysource-4.1.3-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.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 63663a351b57a0dd992f331edd4933726185c00157f4b0c36d8497146dd37555
MD5 0a513ff552ec1e066fac08cb4c47ee9c
BLAKE2b-256 fae7310554f8f26e6c2603fff85e8848897a59d85b5dda4c48c74eea10d2ef82

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.3-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 6319a971cff147ea4c460f88186800edcb374d67ac370bc5bf0675e93494758c
MD5 456fdc4fb69a8754efbc1f30d4c99489
BLAKE2b-256 46c96b81b7af49ea08d6e0a9807bf630654e64fc0156c75a30e2c4995ae19219

See more details on using hashes here.

File details

Details for the file querysource-4.1.3-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.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5ee820526a5bb8dfc01bfc3b3bd6212013b61bac5462f05fcae77669fc71098b
MD5 1994688464aaf2bfef839469dc7acaec
BLAKE2b-256 d40d93f2c97664e3cf3d5d3eb17a2a49091f9adc72806a18e985a832ff0eb330

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