This feels like an error to me, though I can't prove why. Of course, I would prefer:if (! $sth->fetchrow_array()) { #no rows returned } else { # rows returned }
I just would like to know if and why the first might be producing a bug in a program.if ( $sth->rows() == 0 ) { #no rows returned }
In reply to fetchrow_array return value by Notromda
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |