"Insert if not exists" in both MySQL and HSQLDB -
is there sql statement (or atomic sequence of statements) supported both mysql , hsqldb insert values if aren't there?
i'm working on app uses mysql production database , hsqldb unit tests; i'd have single "initial data import when tables empty" script.
mysql supports insert ignore, replace into , insert ... on duplicate key update ..., hsqldb doesn't; conversely, hsqldb supports merge mysql doesn't.
look @ accepted answer here, think way go, if not want preprocess scripts other script.
Comments
Post a Comment