[Sqlalchemy-tickets] Issue #4292: execute fails on postgres if % in statement and no parameters (zz
Brought to you by:
zzzeek
From: Michael D. M. <iss...@bi...> - 2018-06-28 15:26:29
|
New issue 4292: execute fails on postgres if % in statement and no parameters https://bitbucket.org/zzzeek/sqlalchemy/issues/4292/execute-fails-on-postgres-if-in-statement Michael Del Monte: This fails import sqlalchemy e = sqlalchemy.create_engine("postgresql://postgres@localhost:5432/postgres") e.scalar("select 1 where 'a' like 'a%'") with TypeError: 'dict' object does not support indexing because the underlying execution context wants positional arguments so it supplies an empty dict as the "parameters" argument, but psycopg2.cursor.execute wants a tuple. |