Skip to main content

Wrapper for working with Slate databases.

Project description

# Slate DB
A Python wrapper for executing Slate Custom SQL in Python.

## Installation
You must first install the [ODBC Driver for SQL Server](

Then install via pip:
pip install git+

## Usage
The `` method returns a generator which will yield any records that match your `sql` query. By default, each record is returned as an AttrDict, enabling access via keys or via attributes:

>>> from slate_db import SlateDB
>>> db = SlateDB(server='',

# select all records with last name "Smith"
>>> sql = """select * from person where last = 'Smith'"""
>>> for record in
>>> print("Via attribute: {} <{}>".format(,
>>> print("Via key: {} <{}>".format(record['name'], record['email']])
# Via attribute: Smith, John <>
# Via key: Smith, John <>
# Via attribute: Smith, Granny <>
# Via key: Smith, Granny <>

Project details

Download files

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

Files for slate-db, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size slate_db-0.1.1-py3-none-any.whl (3.1 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size slate_db-0.1.1.tar.gz (2.7 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page