added example for sqlalchemy expressions
This commit is contained in:
parent
f3533de1a7
commit
128d4a10cb
@ -102,6 +102,10 @@ Of course the main reason you're using a database is that you want to use the fu
|
|||||||
for row in result:
|
for row in result:
|
||||||
print row['country'], row['c']
|
print row['country'], row['c']
|
||||||
|
|
||||||
|
If you are familiar with `SQLAlchemy query expressions <http://docs.sqlalchemy.org/ru/latest/orm/query.html#the-query-object>`_ you can use them, too::
|
||||||
|
|
||||||
|
q = session.query(MyClass).filter_by(name = 'some name')
|
||||||
|
result = db.query(q)
|
||||||
|
|
||||||
Exporting data
|
Exporting data
|
||||||
--------------
|
--------------
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user