Re: [sqlalchemy] postgres timestamp at time zone

2012-11-19 Thread Michael Bayer
is this psycopg2 ? If you use Python datetime objects with the tz attribute set, it should just work, psycopg2 should do that conversion for you (haven't checked, but typically they are pretty good in this area). Otherwise there are some SQLAlchemy routes to this, including the @compiles

Re: [sqlalchemy] postgres timestamp at time zone

2012-11-19 Thread espresso maker
Yes, It's psycopg2. I wasn't aware that it does the conversion itself until after I posted my question. I ended up doing what you said. :) Thanks! On Monday, November 19, 2012 7:27:01 AM UTC-8, Michael Bayer wrote: is this psycopg2 ? If you use Python datetime objects with the tz

[sqlalchemy] postgres timestamp at time zone

2012-11-18 Thread espresso maker
Hi, I have a table 'my_log' with a created_at column of type timestamp with time zone; class Log(Base): __tablename__ = my_log created_at = Column(DateTime(timezone=True), nullable=False, server_default=func.now()) I would like to query Log and