sql在insert时判断有无唯一性冲突,存在相同主键或唯一索引,则不创建
INSERT INTO table(field1, field2, fieldn) SELECT 'field1', 'field2', 'fieldn' FROM DUAL WHERE NOT EXISTS(SELECT field FROM table WHERE field = ?)
sql在insert时判断有无唯一性冲突,存在相同主键或唯一索引,则不创建
INSERT INTO table(field1, field2, fieldn) SELECT 'field1', 'field2', 'fieldn' FROM DUAL WHERE NOT EXISTS(SELECT field FROM table WHERE field = ?)