dgrafx
asked on
insert to mysql table
what is the syntax to insert a record only if the record doesn't already exist?
say its based on a column named 'testname'
say its based on a column named 'testname'
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
ok - thanks a lot guys
i will test it later - i cant right now
i will test it later - i cant right now
ASKER
thanks a lot guys
ASKER
i need the syntax
the code i would use on sql server is appearing to fail
what i'd normally use is something like
INSERT INTO sometbl
(x,y)
SELECT 'x','y'
WHERE NOT EXISTS (Select 1 from sometbl where x='x' and y='y')
thanks