i have a table ‘tag_article_assoc‘ with [tagId,articleId] fields. i want to
insert new tags for a specific article (lets say articleId=23) but skip records already in db.
i am not sure on the right syntax, any ideas?
INSERT INTO wd_article_tag_assoc (tagId,articleId) VALUES ('$upTag','23') ON DUPLICATE KEY UPDATE...
thanks
S
I suppose you have the tagId,articleId both as primary key in your database
You are welcome to read
"INSERT IGNORE" vs "INSERT … ON DUPLICATE KEY UPDATE"