Hi Guys,
I have a table of contributors like so:
contribid/email/name/surname/url/created/displayname
contribid auto increments.
I want to add a new contributor to the table if his email address doesn't already exist in the table. I thought the following would work but I get a syntax error:
INSERT INTO contributors(email, name, surname,url, displayname) VALUES('someone@hotmail.com', 'Joe', 'Bloggs','www,somewhere.com','Joey') where not exists (email='someone@hotmail.com')
Any help would be appreciated.
Thanks,
Tim.