PDA

View Full Version : select row from table, EASY


FJbrian
04-11-2007, 05:42 PM
I'm drawing a blank and can't find it my Sams 24 hour book.

I've got a player name and stats in a DB so a row in the database would look like
Chris Brown 300 1200 5 40 325 2

I need to select(display PHP) Chris Brown and everything associated with him.

I had this all setup and haven't thought of it in years and now....geesh I just feel like an idiot as nothing I've tried works and I know it's connect to DB then one line of code, a select statement.

lil help please?

Daemonspyre
04-11-2007, 06:33 PM
strSQL = "SELECT * FROM `table_name` WHERE `Player_LName` = 'Brown' AND `Player_FName` = 'Chris';"

OR

if Chris Brown's ID record was 12 --

strSQL = "SELECT * FROM `table_name` WHERE `PlayerID` = 12;"

HTH!

FJbrian
04-12-2007, 04:39 AM
thanks