I need help reading data from a mysql database in php.?

toad

New member
Your select statement would look something like this:

SELECT lastname FROM table_name WHERE firstname='firstname'
 
This page: http://www.w3schools.com/PHP/php_mysql_select.asp

shows most of what i need except it collects all of the data from the table. I want to read only one.

Let's say I know what the first name of the person is. What I would like to know is how I can retrieve that persons last name and then make it appear where I want it to on my page.
 


Write your reply...
Back
Top