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.9.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.9-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.9-cp313-cp313-manylinux_2_28_x86_64.whl (13.4 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

querysource-4.1.9-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.9-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.9-cp311-cp311-musllinux_1_2_x86_64.whl (13.3 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.1.9-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.9-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.9-cp310-cp310-manylinux_2_28_x86_64.whl (12.4 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

File details

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

File metadata

  • Download URL: querysource-4.1.9.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.9.tar.gz
Algorithm Hash digest
SHA256 5a63807cc780cdec64f283e27f7bceee72be22814a30b9767d4d27a11eff7430
MD5 cfa6f22aff0eca65ec112d1af705b780
BLAKE2b-256 c0a4864d9dcabee540b6ca100873cdd090e9ed5fa5ed6e7f1a0d2a077c9dad0f

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 cd345e99a6810dbb355b7dca51c323f6113d75ee2edd3fab72ee09b12ee21782
MD5 9e3b6c64324ab5336035993b9e9b550e
BLAKE2b-256 5cd42f85db70e0036b180653cbae86e18a4e3940cc76c6a82e5a2c679cedb17d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ba19b3e906a1b55eae9205ed11a89654c86c4df8fc6e00fe848f0e5673522664
MD5 3546111eb33d6ccc3f435654d2f8e256
BLAKE2b-256 27380e863e7e5667ddff78019c2bf3c5caf5a553d868d939dc55d1921dc9a183

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 83bedd62594b799ff6adaf35ad5457edfbb84002e7c098618ac35211ab9744c9
MD5 b2d6defef3299bd4c52974d83a16c77f
BLAKE2b-256 a9b42b8ad946a835a04918a858519cfc67a600f37bbe5940706208a502c38028

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 1c5c980bade7bf164a1a8fe9fcbf14680113ab6fe9ef7c42a1139643ea2dcbf5
MD5 ce49c046d78b9890833d92a13e33a95b
BLAKE2b-256 b2528bd24f0ec1ea08a539c02ea8854d2262b445960a7e7a51b39b9f2344f69c

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 8e2c5a35d284342eafb612fc9f2dfb2bd5ba4f5ba4f963302b72cd3b0456bbc4
MD5 2afb1c3115b7e8f0a8425d0d888fc25f
BLAKE2b-256 0c4aacea100355b1ee92bba6240eeceb7a70a3967c5916bfc9efe54e1331db20

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b41dd328a3734bce9404a63ad8c76b05ebd92407baea4718dbf1659a0d8029bc
MD5 69332f66180ac2fab7648397ac11ab44
BLAKE2b-256 ada561a271b6d1932f09a46da8ea15032cc444112519d55ca4305953f383a47e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 abf17bc233d5bed0c838333d88b605689ba8e278c4da9c6cee694da70e2d2cc0
MD5 d70ecb80fcae855363efedd6351e0897
BLAKE2b-256 3696fefbe4c34c231dd98c168c4dd3e9260672e93d76f0ecfefba88b34e67890

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.1.9-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 dea89ead579c4ac6571d3e963b1ac669e3ec5c18e38949029c8e365e72b20092
MD5 e4254dd2af1ea16543c6457fc5ff7873
BLAKE2b-256 2e356c318a68182bc05dda932e6d2698a8de8d8e87e63cf3e3d6b1eaf9edfed4

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