The following code is DB specific: import sqlalchemy # ... ergebnis = session.query( my_object.attr1).filter(sa.and_( my_object.attr2 != 'NaN')).all() # PostgreSQL # my_object.attr2 != None)).all() # sQLite
With PostgreSQL it is "'NaN'", with SQLite "None" (without single quotes). Is there a SQLAlchemy-way to do this backend independant? -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com. To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.