Skip to main content

qSQLA is a query builder for SQLAlchemy Core Selectables

Project description

qsqla
===============================

[![Build Status](https://travis-ci.org/blue-yonder/qsqla.svg?branch=master)](https://travis-ci.org/blue-yonder/qsqla)

qSQLA is a query builder for SQLAlchemy Core Selectables

Installation / Usage
--------------------

To install use pip:

$ pip install qsqla


Or clone the repo:

$ git clone https://github.com/blue-yonder/qsqla.git
$ python setup.py install

Example
-------


```python

from sqlalchemy import create_engine, MetaData, Table, Column, Integer, String


db = create_engine("sqlite:////:memory:")
md = MetaData(bind=db)

table = Table('user',
md,
Column('id', Integer, primary_key=True),
Column('name', String(16), nullable=False),
Column('age', Integer)
)

sel = table.select()

from qsqla.query import query, build_filters
filter = build_filters({"id__eq":1})
stm = query(sel, filter)

```

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qsqla-0.3.1.tar.gz (17.9 kB view details)

Uploaded Source

File details

Details for the file qsqla-0.3.1.tar.gz.

File metadata

  • Download URL: qsqla-0.3.1.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.14

File hashes

Hashes for qsqla-0.3.1.tar.gz
Algorithm Hash digest
SHA256 228d206c1d885e80d182ccd5ae2844564357e0be70e22219abbf9c1452737123
MD5 d364549b26584e66d57d633dca63b37b
BLAKE2b-256 4d129cba275fcc3daa0d10b9fa9351ec9c096229596fd366e951d5dd0e046a27

See more details on using hashes here.

Supported by

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