I'm trying to filter a table on a column that contain spaces.
...
events = database_session.query(table)
events.filter(table.column with space == 'xvalue') < -- I want to do that
...
There is for sure a simple way of doing that, but I can't seem to find it anywhere.
There are two ways to resolve this.
t_table_name = Table(
'tablename',
metadata,
Column('SQL Column', Integer, key='sql_column')
)
class Employee(Base):
emp_name = Column("employee name", String)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With