List:General Discussion« Previous MessageNext Message »
From:Michael Stassen Date:November 30 2005 5:08pm
Subject:Re: Newbie Question on Update
View as plain text  
Kraer, Joseph wrote:
> I am trying to update a couple of rows in a table by doing the
> following:
> 
> update table
> set column5 = number1
> where column 1 = number2
> and column1 = number3

This appears to be correct syntax.

> but it is not working.

We can't help you if you don't tell us what you mean by "not working".  Do you 
get an error message?  If so, what is it?  Do you get unexpected results?  If 
so, tell us what you expected and what you got.

> I tried listing the conditions separated by
> commas (where column 1 = number2, column1 = number3) and also didn't
> work.  What am I doing wrong?

Because that isn't valid syntax.  Don't make things up.  Read the manual 
instead.  UPDATE syntax is described in detail 
<http://dev.mysql.com/doc/refman/5.0/en/update.html>.

> Thanks in advance,
> 
> Joseph "Tito" Kraer
> Business Systems Analyst
> Taylor, Bean & Whitaker Mortgage Corp

Michael

Thread
Newbie Question on UpdateJoseph Kraer30 Nov
  • Re: Newbie Question on UpdateMichael Stassen30 Nov
  • RE: Newbie Question on UpdateISC Edwin Cruz30 Nov
  • Re: Newbie Question on UpdateSGreen30 Nov
  • RE: Newbie Question on Updatemel list_php30 Nov
  • Re: Newbie Question on UpdatePeter Brawley30 Nov
RE: Newbie Question on UpdateJoseph Kraer30 Nov