Hi,
looking at CascadeActions::delete (http://search.cpan.org/src/
JROBINSON/DBIx-Class-0.07999_02/lib/DBIx/Class/Relationship/
CascadeActions.pm), the code deletes $self and then goes on to delete
the related objects. Shouldn't this be the reverse?
If a database has FOREIGN KEYs statements with ON DELETE CASCADE, the
second part will never find any elements to delete. Also, even if we
don't have ON DELETE CASCADE at the database level, it makes more
sense to me to first delete the related objects and only then delete
the "parent" object.
Maybe there is a reason to be like this?
Thanks in advance,
--
Pedro Melo
Blog: http://www.simplicidade.org/notes/
Jabber ID: [EMAIL PROTECTED]
Use Jabber!
_______________________________________________
List: http://lists.rawmode.org/cgi-bin/mailman/listinfo/dbix-class
Wiki: http://dbix-class.shadowcatsystems.co.uk/
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/trunk/DBIx-Class/
Searchable Archive: http://www.mail-archive.com/[email protected]/