[sqlalchemy] Re: Joining multiple tables

2007-08-17 Thread Vetle Roeim
On 8/17/07, Michael Bayer [EMAIL PROTECTED] wrote: hi Vetle - the Table object supports a join() method, which can be called in a chain, i.e. table1.join(table2).join(table3)... if you need to specify the ON part of the join, its the second argument to join() (below illustrated

[sqlalchemy] Joining multiple tables

2007-08-16 Thread Vetle
Hi, I'm reading the documentation on SQL Alchemy, but perhaps I'm missing something here ... I need to join multiple tables, table1 with table2 and table1 again. So, in SQL, I'd do something like: select * from t1 join t2 on t1.b = t2.c join t1 t3 on t1.a = t3.a; Yeah, it doesn't make much