I am trying to convert datetime to timestamp format in my table 'mytable'. It gives me an error say: You can't specify target table 'mytable' for update in FROM clause. Was I wrong with update or converting?
UPDATE mytable
SET TimeStampIN = (SELECT UNIX_TIMESTAMP(STR_TO_DATE(timestamp, '%h:%i%p') FROM mytable)