a little orm
Project description
.. image:: http://media.charlesleifer.com/blog/photos/p1423749536.32.png
peewee
======
This is just `peewee-2.10.2 <https://github.com/coleifer/peewee>` with some changes we need:
* Simple LEFT JOIN LATERAL. No need make subquery, just join to model.
.. code-block:: python
# make some compound select query
subq = ModelB.select(ModelB.id).where(ModelB.id > ModelA.id).limit(1)
# make query lateral joining subquery
ModelA.select(ModelA, subq.c.id).join(subq, join_type=JOIN.LATERAL)
* Add off argument to for_update method
.. code-block:: python
# Lock books of author name == John
Book.select().join(Author).where(Author.name == 'John').for_update(of=Book)
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
311devs_peewee-2.10.2.1.tar.gz
(493.6 kB
view details)
File details
Details for the file 311devs_peewee-2.10.2.1.tar.gz
.
File metadata
- Download URL: 311devs_peewee-2.10.2.1.tar.gz
- Upload date:
- Size: 493.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bfb0ce15d64abb7a415b721df2aa16ed14271ce5591039a89a9f75bc1251b4fd |
|
MD5 | b3a4a20d6f5326f6c9588ef02676fd6f |
|
BLAKE2b-256 | ce676ec7c18f246671461e6d5a61b8d2400e85983da85120576fca3aa31d4336 |