On Mon, Mar 24, 2008 at 06:49:48PM +0100, Moritz Onken wrote:
> Am 21.03.2008 um 17:43 schrieb Matt S Trout:
> >On Sat, Mar 08, 2008 at 06:11:22PM +0100, Moritz Onken wrote:
> >>Wouldn't it be great (tm) if we could add an "on_delete" and
> >>"on_update" config
> >>to all the relationships? Like the "cascade_delete" config option.
> >>
> >>If the DMBS supports that type of actions DBIC does not have to take
> >>care of it,
> >>otherwise it does.
> >
> >Seems reasonable, but how well can we abstract it to be non-db- 
> >specific?
> >
> >If we can't, I think just using sqlt_deploy_hook is the answer.
> 
> 
> I'd like to push this a little bit because I think it could be really  
> helpful. For now I applied a patch to the current 0.09 trunk which  
> allow to set on_delete and on_update on a relationship. This will not  
> break backwards comp. but generates the correct ouput if you use SQLT.
> 
> What do you think about a config option which tells DBIC to not handle  
> the trigger actions (on_delete on_update resp. cascade_delete)? If  
> this is set the DBMS is to handle those operations which will result  
> in a significant speed increase.

How about 'software_cascade => 0' to set that, and then later we can default
it to 0 if not supplied and provide a separate 'software_cascade => "delete"'
option?

Patches look good, please make sure they come with tests.

-- 
      Matt S Trout       Need help with your Catalyst or DBIx::Class project?
   Technical Director                    http://www.shadowcat.co.uk/catalyst/
 Shadowcat Systems Ltd.  Want a managed development or deployment platform?
http://chainsawblues.vox.com/            http://www.shadowcat.co.uk/servers/

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/[EMAIL PROTECTED]

Reply via email to