I keep getting an error when i use this update query.

can someone help me please.

update `table` set `column1` = '$varvalue' WHERE `column2` = 'value1' AND `column1`='value2'

for some reason it doesnt work when I put the AND in there and the second column value.