Cake does not support composite primary keys, but a work around would
be to add a single primary key field (id), and then set a unique
constraint on your composite key fields. Same effect, and works with
cake.
If you want to do a custom query, just do $this->modelName-
>query('INSERT INTO MyTable...');
On Aug 23, 6:41 am, . <[EMAIL PROTECTED]> wrote:
> Hi
>
> I have a table with composite primary keys. The primary key consists of 2
> columns. How would I do a row insert?
>
> Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---