Skip to main content

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.

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.5.11.tar.gz (3.2 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.5.11-cp313-cp313-musllinux_1_2_x86_64.whl (11.4 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

querysource-4.5.11-cp313-cp313-manylinux_2_28_x86_64.whl (11.4 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

querysource-4.5.11-cp312-cp312-musllinux_1_2_x86_64.whl (11.5 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

querysource-4.5.11-cp312-cp312-manylinux_2_28_x86_64.whl (11.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

querysource-4.5.11-cp311-cp311-musllinux_1_2_x86_64.whl (11.3 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

querysource-4.5.11-cp311-cp311-manylinux_2_28_x86_64.whl (11.2 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

querysource-4.5.11-cp310-cp310-musllinux_1_2_x86_64.whl (10.4 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

querysource-4.5.11-cp310-cp310-manylinux_2_28_x86_64.whl (10.4 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

File details

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

File metadata

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

File hashes

Hashes for querysource-4.5.11.tar.gz
Algorithm Hash digest
SHA256 757540d2a6ced6415ccba7c20ffeaf4bf0b8489364caeecc19bbce5610cf08a7
MD5 25a01b7ee841360fb2d38cb07db13179
BLAKE2b-256 101ae622acf590dc80c2ea11ed1f61345a371bbe8ea1638ce06f947f5b454fd9

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 658623ace2967c5b473eda267117d59c9b1a69d491b09b94c97f7c30e55fb10a
MD5 29877fe6051a887e5b9128bbb70b0b80
BLAKE2b-256 8508593dba22499aa1304cae7963321b6b03a156c6d129d1d2d1f8bd6c99d327

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 76a5d41552343dd49f9bcff38a0a2bcf68c71ace1cfa4ac4c6bb1361d8fe1a01
MD5 6f5a4d22ad10ef3058e6ef7abeaa23ab
BLAKE2b-256 3d3e1f43cad442fa3a308e01101d8725e462a5aa9c90679669884f525a66b775

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 e165cfa3aef42aed71268857498713f92704216cc5a5ef6883ff2c95c4f62589
MD5 8097954e06853d8313e7997e677b51fa
BLAKE2b-256 1946429c298ef79208223bbaa0969c1a1fdd9bf39d2c6334b6111c8815618347

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ccac6d87337da0b3368aeeaf915a8435722f1e1debfc229e18cf7afdf5d62ee5
MD5 4e6ae4ece0d03a92cb60a851e6cdf1db
BLAKE2b-256 58510b1223d13bb4a820062a24da5cc153b610ae7c07d784b6f5411e44b708da

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 57e36a17e5bac4ca8f2454c98bb08f1a2766c255fc207f2cfddb50bd097c3f70
MD5 395b49301911f0040bbb7021035366cc
BLAKE2b-256 2a0aa56b35577b9ffddf8851e4b27f10399001dbb8063746041023128c26e39f

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 e3546440b972e881dcaa23f6da3e4038a7ddb3a4c5417689da336015492326de
MD5 b489bbaed63ce8595b942f7773fa2a68
BLAKE2b-256 8e99578456531657b31f4560d341e0d162587359c2b82aaac8264979eff75c29

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 af9b010141346781b8d4c38826d36e167cff15bd354c274cdb1f710dbfc6e43b
MD5 9802a3dd9ea51bfa38916dc744d116cb
BLAKE2b-256 4d2dcd1c04cd41cd6ea9c067e12018513583a75a75ca522ba20f563b2e45b673

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for querysource-4.5.11-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 3a27fd75bf732eedba7e49a6d39cc39547af5c70db3b4e6219d2247a17d1f628
MD5 38591f8acb55538f47288d8616dbb802
BLAKE2b-256 7af7c1a0fe5a693cf61909b18f400c9c50e7166ffffd49eb92c72ac0879994b9

See more details on using hashes here.

Release history Release notifications | RSS feed

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page