"Select * from" Alternative?
Posted: Thu Apr 29, 2010 8:13 pm
I'm wondering, sorry if this is stupid (I'm sure it is), if there's an alternative to "Select * from table_name". I want just ONE entry from my table.
Here is my code as of now :
But it doesn't seem to work.. I need that single entry (I don't want an array because it seems like a waste) because the rest of the code executes only if "names" is not null.
Thanks for your help in advance, and a quick response would be really nice; I'd love to have this done tonight before I go to bed
Here is my code as of now :
Code: Select all
$a = mysql_query("SELECT `names` FROM `table_$type` WHERE `id`='$id'") or die(mysql_error());
Thanks for your help in advance, and a quick response would be really nice; I'd love to have this done tonight before I go to bed