<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7638.1">
<TITLE>[Dbix-class] cascade delete problem</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->
<P><FONT SIZE=2 FACE="Arial">Hi,</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">I have a simple cascade delete test that fails under 6.0 but passed under 5.007.</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">my $foo = $schema->resultset('Foo')->create({ foo => 1 });</FONT>
<BR><FONT SIZE=2 FACE="Arial">my $bar = $schema->resultset('Bar')->create({ bar => 1 });</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">$bar->foo($bar);</FONT>
<BR><FONT SIZE=2 FACE="Arial">$bar->update;</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">$foo->delete;</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">is($schema->resultset('Foo')->count, 0, 'foo deleted');</FONT>
<BR><FONT SIZE=2 FACE="Arial">is($schema->resultset('Bar')->count, 0, 'bar deleted (cascade)');</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">Stepping through with the debugger it would appear that it never goes through the CascadeActions code.</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">Any clues where I should start looking with this? I couldn't find an obvious test case in DBIC.</FONT>
</P>
<P><FONT SIZE=2 FACE="Arial">Thanks, Richard</FONT>
</P>
<BR>
<BR>
<br>http://www.bbc.co.uk/<br><br>This e-mail (and any attachments) is confidential and may contain<br>personal views which are not the views of the BBC unless specifically<br>stated.<br>If you have received it in error, please delete it from your system. <br>Do not use, copy or disclose the information in any way nor act in<br>reliance on it and notify the sender immediately. Please note that the<br>BBC monitors e-mails sent or received. <br>Further communication will signify your consent to this.<br><br></BODY>
</HTML>