This works: select([ func.ARRAY( select([t.c.value]) .where(t.c.id<3) .as_scalar() ) .label('array_col') ])
- Gulli On Nov 9, 3:43 pm, Michael Hipp <mich...@hipp.com> wrote: > Can someone show me the gist of how to construct an SA query that > produces SQL* of the form > > SELECT ARRAY(SELECT ... FROM ... WHERE ...) as array_col > > Thanks, > Michael > > *http://www.postgresql.org/docs/8.4/interactive/sql-expressions.html#S... -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalch...@googlegroups.com. To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.