MySQL Forums
Forum List  »  Newbie

Re: set a column in dependency of two others
Posted by: Michael Stahl
Date: January 20, 2015 03:50AM

I solved this with a second SQL statemant where I used a IF function.

UPDATE table SET C=IF(A='1' AND B='1'),1,0) WHERE ID='11'

Options: ReplyQuote


Subject
Written By
Posted
Re: set a column in dependency of two others
January 20, 2015 03:50AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.