[sqlalchemy] Selection of sort directions

2015-12-05 Thread SF Markus Elfring
Hello, The software "SQLAlchemy" supports also the handling of the SQL clause "ORDER BY" to some degree. http://docs.sqlalchemy.org/en/rel_1_0/orm/query.html#sqlalchemy.orm.query.Query.order_by Now I am looking for the corresponding description of details for the specification of the desired

[sqlalchemy] Determination of string lengths

2015-12-05 Thread SF Markus Elfring
Hello, I would like to reuse the standard function "len" for the determination of string lengths from specific database fields in a query. http://www.dailyfreecode.com/code/len-function-296.aspx Which interface does provide this functionality for the software "SQLAlchemy"? Regards, Markus --

[sqlalchemy] Re: Selection of sort directions

2015-12-05 Thread Jonathan Vanasco
Odd- this isn't the narrative docs You can use column attributes... (http://docs.sqlalchemy.org/en/latest/core/sqlelement.html#sqlalchemy.sql.expression.ColumnElement.desc) session.query(model.Foo).order_by(model.Foo.id.desc()) session.query(model.Foo).order_by(model.Foo.id.asc())

Re: [sqlalchemy] Determination of string lengths

2015-12-05 Thread Jeff Widman
This is probably the fastest answer: http://stackoverflow.com/questions/15743121/how-to-filter-in-sqlalchemy-by-string-length ᐧ On Sat, Dec 5, 2015 at 1:34 AM, SF Markus Elfring < elfr...@users.sourceforge.net> wrote: > Hello, > > I would like to reuse the standard function "len" for the