What I'd like to say is something like:
Update a count by 1 if an id exists add it if not.
I have tried the following:
INSERT INTO links (id, count) VALUES (:id, 1)
ON DUPLICATE KEY UPDATE count = count + 1;
which is some PHP code, I can add the ids, but I can't increment the count. Any ideas please?