note
afoken
<blockquote>I am a bit flummoxed as to how you get -1 as the result. </blockquote>
<p>-1 is a legal return value for $sth->execute(). Quoting the [mod://DBI] documentation:</p>
<blockquote>
For a non-SELECT statement, execute returns the number of rows affected, if known. If no rows were affected, then execute returns "0E0", which Perl will treat as 0 but will regard as true. Note that it is not an error for no rows to be affected by a statement. If the number of rows affected is not known, then execute returns -1.
</blockquote>
<p>Alexander</p>
<div class="pmsig"><div class="pmsig-747201">
--<br>
Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
</div></div>
11115668
11115916