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.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.1.1.tar.gz (2.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.1-cp313-cp313-musllinux_1_2_x86_64.whl (12.4 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.1.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.5 MB view details)

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

querysource-4.1.1-cp312-cp312-musllinux_1_2_x86_64.whl (12.5 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.1.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.6 MB view details)

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

querysource-4.1.1-cp311-cp311-musllinux_1_2_x86_64.whl (12.3 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.1.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (12.3 MB view details)

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

querysource-4.1.1-cp310-cp310-musllinux_1_2_x86_64.whl (11.5 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.1.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (11.5 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.1.tar.gz.

File metadata

  • Download URL: querysource-4.1.1.tar.gz
  • Upload date:
  • Size: 2.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.1.tar.gz
Algorithm Hash digest
SHA256 f79ee1b9707dc9b25ca2e2bdf2ccad1291a03fa2e88fd2b193e50180385aba5b
MD5 9435fcf95d7f57ec944eebe00bd007de
BLAKE2b-256 8495ad744978df43d49cd4bb9dfd21d5c1f7d2e75651a4648de756bd437003aa

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.1-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 72f8b32d8676cf4ee8051f79b8e16b06c2b7de1d7697fe5c573e563f9fa1659a
MD5 ce884c73f11f1db1588dbdf1fda93eb8
BLAKE2b-256 83fa523cedeba4446d45797be5d41af0d887d6d91b1c285d8c5dca8c72256a9f

See more details on using hashes here.

File details

Details for the file querysource-4.1.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.1.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 70d3154ba368d4f7969102c3c2b462427e68c02d191cdeff4624d2383d3a46c9
MD5 8afe2b7e6f566566f637c5211e4d7eff
BLAKE2b-256 110cb17c4d199a1da95856991b182767346cd85519c5de977e81d9147c0b20f7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.1-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 7819bd3b31d4e7122bc482f78c58673547d8f8e0ef79798c063608754ab1b4fe
MD5 6e40118255c435a497b7ede6aa229435
BLAKE2b-256 3e06daa79a9b733b01ea500891ff0812aea04d0c05eaf0aac5cad47ef6673ef8

See more details on using hashes here.

File details

Details for the file querysource-4.1.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.1.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 c833e9aabb5909cf42cc22ffabdc00312d9e53dd3647bb3f9514d8fe9d6cd95e
MD5 0a070764b5b44b08cabd91dfc2fde71b
BLAKE2b-256 c7672ceb3eabd78a1105b01678972ad82f2c7530e5b0841c7c6b96b1031eaee4

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.1-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 ff5957cd1cc6a14460ab99248fe0ff69dc44d32f4e16f00ccfbe7beebb0287ce
MD5 2a867c44eb908d57f1f557d1ef5d94f6
BLAKE2b-256 455c46dcdfb67e301916602d3ac010b0e550a8dc6a7e0b61dd1af362c65e593c

See more details on using hashes here.

File details

Details for the file querysource-4.1.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.1.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ab635756a0a296182efc2cd832741bea5c43dcd39ec9de316a90e4381eb80499
MD5 7d7545fae4e561310311656f4cc82461
BLAKE2b-256 872ff6404f3755efa641da3a5410722af6e7126b5f9b3bd42f1b2047d05292de

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.1-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 11a8a786b82e2f5763004e87e53a003e48f52ff9b97bd46f13f46d62d21e5a1d
MD5 105f43799fa0eaf8050ad8c22b45f47e
BLAKE2b-256 a367967790a5be888f6f17f2054f0473b0eb79c2365850b9e7adc6227336f93a

See more details on using hashes here.

File details

Details for the file querysource-4.1.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.1.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 335cd454c03d951cbc15c9c5a425c98a64a448aa0377fe53765e7e62f9c7b1d5
MD5 b6c60166a93927e27605faa500f8ef4d
BLAKE2b-256 7fc90b38c2a9633460f5879adaacb4594616b730dea942c4abb3a5e568b1fa8a

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