checking coloumName value before update. if value of coloumName = 1 then 0,if coloumName = 0 then 1. Get link Facebook X Pinterest Email Other Apps May 24, 2017 UPDATE `tableName ` SET ` couloumName `= IF (coloumName = 1 , 0 , 1 ) WHERE id = Idvalue Read more