I'm new at this and I'm hung up on getting a simple query to work. Can anyone please explain why I'm getting these results?
This doesn't (but I thought it should) bring back any results:
$name = "homer";
// and I've tried $name = 'homer';
$sql ="SELECT * FROM User WHERE name=$name ";
$result = mysql_query( $sql , $dbName );
But this does:
$sql ="SELECT * FROM User WHERE name='homer' ";
$result = mysql_query( $sql , $dbName );