Re: Deleting from $film->stars in Many to Many Example

[prev] [thread] [next] [Date index for 2004/11/22]

From: Perrin Harkins
Subject: Re: Deleting from $film->stars in Many to Many Example
Date: 16:47 on 22 Nov 2004
On Mon, 2004-11-22 at 11:41, Peter Speltz wrote:
> In the many to many example in Docs, what's best way to delete a star from a
> film which deletes the Role) ?  Write a custom sub?

If you delete the roll, that means you want to delete all stars attached
to it.  Class::DBI already does the cascading delete for you, so just
delete the role and it takes care of the rest.

- Perrin

Re: Deleting from $film->stars in Many to Many Example
Perrin Harkins 16:47 on 22 Nov 2004

Generated at 17:24 on 02 Dec 2004 by mariachi v0.52