hello all!

i want to duplicate not ony one table record, but that record and it's
associated records, and have the foreign keys changed to reflect the
new insert_ids.

for example, i have this association:

weeks->days->hours

i want to duplicate the week, it's days and hours too. So the foreign
keys would be like this:

weeks
week_id

days
day_id
week_id

hours
hour_id
day_id

ass you can see from the diagram, a new weeks.week_id would be
created, which would have to replace the week id in the days table.
the days.day_id would have to do the same cascade effect in the hours
table, since day_id and hour_id would also be new key_ids.

I believe this behavior exists in the saveall method when a new record
is inserted. But not positive. Any help would be appreciated! -bp

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to