I'd write
while( my $rows= 0 + $dbh->do(...) ) {
in this case.
I'd prefer "00" but it looks less like a real number to some people than "0E0". Therefore, "0.0" might be an even better choice.
I like the feature. It makes it easy to pick whether you want to care about number of rows or about success (simply add "0+" or "0==" or don't).
When RaiseError is turned on, it isn't useful. So I could see adding an option for PlainZero which would default to "never" (for compatability) but could be changed to "always" or "only when RaiseError is off". Though I probably wouldn't use such a feature since I see too much risk from action-at-a-distance with it.
- tye
In reply to Re^2: The Naughty Nought "OEO" blues (simpler)
by tye
in thread The Naughty Nought "OEO" blues
by rinceWind
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |