Re: [sqlalchemy] Re: PostgreSQL hstore custom type?

2012-05-15 Thread Kyle Schaffrick
On Mon, Apr 30, 2012 at 8:52 AM, Adam Tauno Williams awill...@whitemice.org wrote: On Sun, 2012-04-15 at 05:32 -0700, Kyle Schaffrick wrote: Wow, a blast from the past! :) Yes. Which version of SQLAlchemy does your new version work with? It's great that you are now able to get rid of

[sqlalchemy] Syntax Error on *legitimate* statement using Informix dialect

2012-05-15 Thread Adam Tauno Williams
I'm use the Informix dialog with SQLalchemy 0.7.7 (the latest 0.7.x release). It works. But now I'm getting this error - sqlalchemy.exc.ProgrammingError: (ProgrammingError) SQLCODE -201 in PREPARE: 42000: Syntax error or access violation 'SELECT xrefr.xr_serial_no AS xrefr_xr_serial_no,

Re: [sqlalchemy] Execute statement after each connect.

2012-05-15 Thread Oliver Tonnhofer
Hi Simon, On Mon, May 14, 2012 at 7:26 PM, Simon King si...@simonking.org.uk wrote:  http://docs.sqlalchemy.org/en/rel_0_7/core/events.html#sqlalchemy.events.PoolEvents.connect 'connect' event handlers look like this:  connect(dbapi_connection, connection_record) Can't you use the

[sqlalchemy] alias() in Oracle generates incompatible (subquery) AS alias_name

2012-05-15 Thread Karl
Background: I'm recently new to SQLA but not new to data access layers/object relational mapping. Problem: I'm trying to alias a subquery in sqlachemy in Oracle but the AS keyword gets added to the alias, which is not Oracle compatible. Oracle 10.02.03 cx_Oracle 5.0.4 sqlalchemy: 0.7.5 Given

[sqlalchemy] Missing Table documentation?

2012-05-15 Thread Rodney Barnett
Shouldn't the select() method be included in the Table class documentation? The following exception shows where I expected it and can be seen online here: http://docs.sqlalchemy.org/en/latest/core/schema.html#sqlalchemy.schema.Table.get_children. ===

Re: [sqlalchemy] Syntax Error on *legitimate* statement using Informix dialect

2012-05-15 Thread Michael Bayer
Could be tough, you'd need to test it against the informix dbapi directly, using bound parameters, to see what it needs. Could be a typing issue. Sent from my iPhone On May 15, 2012, at 11:36 AM, Adam Tauno Williams awill...@whitemice.org wrote: I'm use the Informix dialog with SQLalchemy

Re: [sqlalchemy] alias() in Oracle generates incompatible (subquery) AS alias_name

2012-05-15 Thread Michael Bayer
When you say print statement, you are not using the oracle dialect, it uses a default dialect. To compile against a specific dialect it's like query.statement.compile(dialect=oracle.dialect()) where oracle dialect is from sqlalchemy.dialects import oracle. Sent from my iPhone On May 14,

Re: [sqlalchemy] alias() in Oracle generates incompatible (subquery) AS alias_name

2012-05-15 Thread Karl
Thanks Michael, much appreciated. I realized that this afternoon when I tried executing the statement and it worked, verified also with my engine(echo=True). Great job on the ORM! On Tuesday, May 15, 2012 1:31:44 PM UTC-7, Michael Bayer wrote: When you say print statement, you are not using

Re: [sqlalchemy] Syntax Error on *legitimate* statement using Informix dialect

2012-05-15 Thread Adam Tauno Williams
On Tue, 2012-05-15 at 16:27 -0400, Michael Bayer wrote: Could be tough, you'd need to test it against the informix dbapi directly, using bound parameters, to see what it needs. Could be a typing issue. Ok, I got a response from an Informix guru and maintainer of the informix dbapi. quote

[sqlalchemy] Wired connection problem

2012-05-15 Thread limodou
Recently I found a wired problem in my application, something like this: I have a long time deamon program, it'll be an infinite loop, just like: engine = create_engine('...') conn = engine.connect() while True: for row in select: update sleep(xxx) In the loop, I create conn at

Re: [sqlalchemy] Syntax Error on *legitimate* statement using Informix dialect [SOLVED]

2012-05-15 Thread Adam Tauno Williams
On Tue, 2012-05-15 at 19:51 -0400, Adam Tauno Williams wrote: On Tue, 2012-05-15 at 16:27 -0400, Michael Bayer wrote: Could be tough, you'd need to test it against the informix dbapi directly, using bound parameters, to see what it needs. Could be a typing issue. Ok, I got a response