Im trying to do an UPDATE statement.
UPDATE `users` SET
`Email` = 'email@domain.com',
`Mobile` = '123456789',
`City` = 'Chicago',
`Firstname` = 'John',
`Lastname` = 'Smith',
`DOB` = '1980-01-01',
`Sex` = 'male'
#1062 - Duplicate entry '123456789' for key 'Mobile'
But I'm updating the record with the same mobile number. Why will it not accept ? I think I got to do something on the lines of UPDATE table ON DUPLICATE KEY update-other-fields.
whereclause, that statement attempts to update the whole table with those values! – Mat Dec 10 '12 at 12:16