I have a table where I would like to fetch all the column names however after browsing the interwebs I could not find a way that works. This is what my table looks like:
You get all of the columns from __table__.columns:
__table__.columns
myTable.__table__.columns
or
myTable.__table__.c
The columns would be in format myTable.col1 (table name is included). If you want just column names, get the .key for each column:
myTable.col1
.key
[column.key for column in myTable.__table__.columns]