[SQLObject] Handling relations with multiple keys
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
From: Bruno T. <bt...@as...> - 2003-06-20 23:22:51
|
Hi there Continuing my experiences on using SQLObject I fall in another question: is it possible to have a object linked to some other using more than one table attribute as foreignKey ? My problem is: I have a Product Class and this product has a SubFamily object which defines some extra product properties to me. It happens that to query products for its subfamily I have to do a comparsion using 2 fields from the subfamily table (subfamilly_id and family_id). Using the foreignKey Col Class atribute I'm able, AFAIK, to set only one field, which in my case isn't enough to pick the unique subfamily object. How to handle this ? []'s Bruno Trevisan bt...@as... |=3D| Async Open Source |=3D| D. Alexandrina, 253= 4 http://www.async.com.br/ |=3D| +55 16 261-2331 |=3D| 13566-290 |=3D| +55 16 9781-8717 |=3D| S=E3o Carlos, SP, B= rasil |