Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Mystified by why my UPDATE statement is not reflected in my database display

by nikosv (Hermit)
on Jul 05, 2013 at 20:32 UTC ( #1042793=note: print w/ replies, xml ) Need Help??


in reply to Mystified by why my UPDATE statement is not reflected in my database display

I haven't checked your code but 'execute' will always return a true value if it run successfully regardless if it actually updated,in this case, or not.

Most drivers will return '0E0' , and mysql's in particular, when the statement runs without errors but has updated 0 rows

so it's best to use :
if ($rv eq '0E0')


Comment on Re: Mystified by why my UPDATE statement is not reflected in my database display
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1042793]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (14)
As of 2015-07-06 12:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (73 votes), past polls