No no.
INSERT ON DUPLICATE KEY UPDATEwill find the record and update it in the same way as it makes simple UPDATE.
This is actually just UPDATEwhat follows INSERTif a failure UPDATE.
INSERT ON DUPLICATE KEY UPDATE can be a faster alternative to group updating (when you have a source table with several records per key and you want to increase the target table once per record).
, :
INSERT
INTO t_target
SELECT target, cnt
FROM t_sparse d
ON DUPLICATE KEY UPDATE
t_target.cnt = t_target.cnt + d.cnt
, :
INSERT
INTO t_target
SELECT target, cnt
FROM (
SELECT target, SUM(cnt) AS cnt
FROM t_sparse di
GROUP BY
target
) d
ON DUPLICATE KEY UPDATE
t_target.cnt = t_target.cnt + d.cnt
. :