![]() |
SELECT statement
Hey guys I have been working on getting my selct statement to work for some time now and just can not get it to work I did manage to get it to stop returning errors but now it returns a blank page, so i went in to my DBMS and opend up the table double checked that i have every thing spelled the same as it is in there. I would be greatful if you could look at the code for me.
Quote:
|
Re: SELECT statement
Kelvoron, how long have you been around, now? Not long enough to distinguish the differnce between code tags and quote tags? If you don't have two brain cells, try to rent one or two.
|
Re: SELECT statement
$tabLE_name and $table_name aren't the same thing. Make sure you have php error display enabled.
|
Re: SELECT statement
Oh my bad i changed it. it still does not work thoug thanks for cathing that for me Dameon. I checked my code against othr peoples and bought a MySQL book the code looks corect as far as i can see but i still get no return
i changed echo(results); to echo $results now it displays " Resource id #2 " X| |
Re: SELECT statement
Check your book regarding what "resource" means. As an example, a FILE * in C does not represent the contents of a file. It is merely an access mechanism.
|
Re: SELECT statement
Any basic example of the PHP MySQL functions will show you what to do with your $result variable. You certainly don't try to convert it to a string and display it. Reread your book and the online documentation before simply asking around for the next line -- both contain working examples that you can build from with a little personal effort.
|
Re: SELECT statement
Look into the mysql_fetch_row() function, passing in your $result variable as the parameter.
|
Re: SELECT statement
The Variable names are case sensitive in PHP. See the variable you have used for table name.
Sanjay Aggarwal |
Re: SELECT statement
Quote:
|
Re: SELECT statement
Quote:
Just a thought, though. |
| All times are GMT -5. The time now is 3:28 AM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC