I'm looking in the comments here and I ran into a problem:
/**
* Zend_Db_Table assumes that if you have a compound primary key
* and one of the columns in the key uses a sequence,
* it's the _first_ column in the compound key.
*/
According to this, it assumes the first key in a compound key is the sequence. Err, that's not true. Is there anyway to overwrite this assumption? We have tons of tables with quite complex cascading keys (some cases, 5 columns) and the sequence key is often the find column in the list.
I'm running into an issue right now where we have one table with a two column compound key. The first column is a static number (related to our client numbers) and the second column is the sequence number. When I do an insert() it returns only the first column. This is against an Oracle DB, with a trigger on insert to mimic auto_increment (although, it's a sequence). I've tried setting the sequence to the sequence name and just leaving the default. Both cases, I only get 1 key of the compound PK back. I think it's related to the above column.
Are there any hooks within Zend_Db_Table_Abstract I can use to overwrite this default / assumed behavior?
--
Philip
gp@...http://www.gpcentre.net/