i need to know the format to search for a user name in the database, im using PHP to submit the data
so far this is what ive got
@mysql_select_db("$DBName") or die("Unable to select
database $DBName");
$sqlquery = "INSERT INTO $table
VALUES('$id','$name','$email','$opinion')";
$results = mysql_query($sqlquery);
mysql_close();
im using that to insert the data into the database, but i need to know the format to search the database to make sure that the username isnt already in use.
$sqlquery = "SEARCH * FROM table WHERE name =(username user wants)";
but i dont know how to tell it to output if the user name has infact been found or if it has not and the user name is good. any help would be greatly appreciated.