in reply to Moose: Can't call method "insertcount" on an undefined value

You forgot to call the committoDB method as a method:
if (defined($commitvalue) && ($commitvalue == 1)) { print "Yes, commit! Commitvalue = $commitvalue\n"; $self->committoDB; # <- HERE } elsif ($counter == $self->commit) { $self->committoDB; # <- and HERE! }

$self was undef because of this, and $self->insertcount had to fail.

($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,

Replies are listed 'Best First'.
Re^2: Moose: Can't call method "insertcount" on an undefined value
by timtowtdi (Sexton) on Sep 27, 2016 at 10:54 UTC
    Thank you for the clear answer. Problem solved!
    The great mistake is to anticipate the outcome of the engagement; Let nature take its course, and your tools will strike at the right moment.