Python mysql check for duplicate before insert
Posted
by Michelle Jun Lee
on Stack Overflow
See other posts from Stack Overflow
or by Michelle Jun Lee
Published on 2010-04-02T01:09:50Z
Indexed on
2010/04/02
1:13 UTC
Read the original article
Hit count: 400
Hi
here is the table
CREATE TABLE IF NOT EXISTS kompas_url
(
id BIGINT(20) NOT NULL AUTO_INCREMENT,
url VARCHAR(1000),
created_date datetime,
modified_date datetime,
PRIMARY KEY(id)
)
I am trying to do INSERT to kompas_url table only if url is not exist yet
any idea?
thanks
© Stack Overflow or respective owner