Re: [PHP] Re: order of update??
On Fri, 24 Aug 2001 04:57, Gerard Samuel wrote: > Im currently hacking away at a current setup that uses php/mysql on a > user table. I have successfully inserted and selected from it, but I > cannot update. Yes there were quotes, but thanks for letting me know > that the order didn't matter, that narrows my list of possibilities > down. Talk to you all later. > trini0 > > [EMAIL PROTECTED] wrote: > > Gerard Samuel <[EMAIL PROTECTED]> wrote: > >>My seem stupid to some, but when running > >>update tablename set x='$x', y='$y', z='$z' where a=$a; > >>Does it matter if it the set were in backwards order ie z, y, x ?? > > > > the order does not matter. (although unless you're sure $a is an > > integer value, you may want to wrap it in quotes, too.) > > > > jim As a debugging aid, use mysql_error() to trap any error messages returned from the database, and mysql_affected_rows to determine the number of rows affected by your update query. It _might_ be that your query is valid, but actually no rows meet the criteria for update? -- David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA "His Honor is crazy," Tom admitted judgementally. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Re: order of update??
No visible errors per se. When I run the script, it either doesn't update the database or if I specify the password, it deletes the entry in the database. Its something on my end. I got to look it over, Thanks Sam Masiello wrote: > Why "can't you update" ? What error message are you getting? > > Sam Masiello > Software Quality Assurance Engineer > Synacor > (716) 853-1362 x289 > [EMAIL PROTECTED] > > -Original Message- > From: Gerard Samuel [mailto:[EMAIL PROTECTED]] > Sent: Thursday, August 23, 2001 3:28 PM > To: PHP > Subject: Re: [PHP] Re: order of update?? > > Im currently hacking away at a current setup that uses php/mysql on a > user table. I have successfully inserted and selected from it, but I > cannot update. Yes there were quotes, but thanks for letting me know > that the order didn't matter, that narrows my list of possibilities > down. Talk to you all later. > trini0 > > [EMAIL PROTECTED] wrote: > > Gerard Samuel <[EMAIL PROTECTED]> wrote: > > > >>My seem stupid to some, but when running > >>update tablename set x='$x', y='$y', z='$z' where a=$a; > >>Does it matter if it the set were in backwards order ie z, y, x ?? > >> > > > > the order does not matter. (although unless you're sure $a is an > > integer value, you may want to wrap it in quotes, too.) > > > > jim > > > > > > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Re: order of update??
Why "can't you update" ? What error message are you getting? Sam Masiello Software Quality Assurance Engineer Synacor (716) 853-1362 x289 [EMAIL PROTECTED] -Original Message- From: Gerard Samuel [mailto:[EMAIL PROTECTED]] Sent: Thursday, August 23, 2001 3:28 PM To: PHP Subject: Re: [PHP] Re: order of update?? Im currently hacking away at a current setup that uses php/mysql on a user table. I have successfully inserted and selected from it, but I cannot update. Yes there were quotes, but thanks for letting me know that the order didn't matter, that narrows my list of possibilities down. Talk to you all later. trini0 [EMAIL PROTECTED] wrote: > Gerard Samuel <[EMAIL PROTECTED]> wrote: > >>My seem stupid to some, but when running >>update tablename set x='$x', y='$y', z='$z' where a=$a; >>Does it matter if it the set were in backwards order ie z, y, x ?? >> > > the order does not matter. (although unless you're sure $a is an > integer value, you may want to wrap it in quotes, too.) > > jim > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Re: order of update??
Im currently hacking away at a current setup that uses php/mysql on a user table. I have successfully inserted and selected from it, but I cannot update. Yes there were quotes, but thanks for letting me know that the order didn't matter, that narrows my list of possibilities down. Talk to you all later. trini0 [EMAIL PROTECTED] wrote: > Gerard Samuel <[EMAIL PROTECTED]> wrote: > >>My seem stupid to some, but when running >>update tablename set x='$x', y='$y', z='$z' where a=$a; >>Does it matter if it the set were in backwards order ie z, y, x ?? >> > > the order does not matter. (although unless you're sure $a is an > integer value, you may want to wrap it in quotes, too.) > > jim > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]