I have a database structured as follows:
users
userid (Primary Key) username
group
IF NOT EXISTS (select * from users where username = 'username') BEGIN INSERT INTO ... END