Skip to main content

Prepares PostgreSQL queries for execution in more useful Pythonic way. Not ORM.

Project description

Prepares PostgreSQL queries for execution in more useful Pythonic way. Not ORM.

>>> from pssq import Q
>>> Q.SELECT().FROM("foo").WHERE(a=5).END()
('SELECT * FROM "foo" WHERE "a"=$1', (5,))

>>> Q.INSERT("foo").SET(a=5, b=7).END()
('INSERT INTO "foo" ("a", "b") VALUES ($1, $2)', (5, 7))

>>> Q.INSERT("foo").SET(q=Q.Unsafe("4"), w=Q.Unsafe("now()"), a=5).END()
('INSERT INTO "foo" ("q", "w", "a") VALUES (4, now(), $1)', (5,))

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 pssq, version 0.0.1
Filename, size File type Python version Upload date Hashes
Filename, size pssq-0.0.1.tar.gz (3.2 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page