[sqlalchemy] Re: Using database functions in UPDATE statement

2008-09-19 Thread Hans Lellelid
In response to myself ... I discovered that it was only when I was specifying the function clauses as bind params in the conn.execute() method that it was failing. The code I presented should actually be working correctly. To be explicit, this seems to be working:

[sqlalchemy] Re: Using database functions in UPDATE statement

2008-09-19 Thread Michael Bayer
On Sep 19, 2008, at 12:52 PM, Hans Lellelid wrote: Hi, I'm using SA 0.4.6 and I'm having trouble using the result of a database function / stored procedure in an UPDATE statement (being constructed with SQL expression lang). This happens to be for using PostGIS columns; however, that

[sqlalchemy] Re: Using database functions in UPDATE statement

2008-09-19 Thread Michael Bayer
On Sep 19, 2008, at 1:18 PM, Hans Lellelid wrote: In response to myself ... I discovered that it was only when I was specifying the function clauses as bind params in the conn.execute() method that it was failing. The code I presented should actually be working correctly. To be

[sqlalchemy] Re: Using database functions in UPDATE statement

2008-09-19 Thread Hans Lellelid
ah.   right, the parameter argument of execute() does not handle SQL   expressions as values - the keys are used to generate a corresponding   list of bind parameter clauses.   Earlier versions of SQLA were more   liberal in this regard but the current behavior was based around   simplifying

[sqlalchemy] Re: Using database functions in UPDATE statement

2008-09-19 Thread Michael Bayer
On Sep 19, 2008, at 1:54 PM, Hans Lellelid wrote: ah. right, the parameter argument of execute() does not handle SQL expressions as values - the keys are used to generate a corresponding list of bind parameter clauses. Earlier versions of SQLA were more liberal in this regard but the