Re: Problem with retrieving Data with MySQL

From: Date: Thu, 18 Jul 2002 19:24:20 +0000
Subject: Re: Problem with retrieving Data with MySQL
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-20635@lists.php.net to get a copy of this message
It might help if you send the list an indication of what $sql (the query) looks like. The only thing it appears to be returning is what was initially sent to the function. Maureen "Blaine D. Dinsmore" <dinsmoreb@surfbest.net> said: > Can somone tell me what is wrong with my code here? > My e-mail does not mail me the results from the the latest database entry: > > ////////////////////////////////////////////////////// > // Mail Handler Routine > ///////////////////////////////////////////////////// > > function mailer($issue,$host,$sql){ > > $dbase="lims_issues"; > mysqlconn($dbase,$sql); > While($row = mysql_fetch_assoc($result)){ > $pid = $row["probid"]; > $lid = $row["loggerid"]; > $ldate = $row["date"]; > $pty = $row["priority"]; > $ifc = $row["interface"]; > $scr = $row["screen"]; > $desc = $row["descript"]; > } > mail("dinsmoreb@michigan.gov","Issue ID: $issue","A New Issue Has Been > Logged! \n\n". > " Issue ID: $pid \n". > " Logged By: $lid \n". > "Remote Host: $host \n". > " Log Date: $ldate \n". > " Priority: $pty \n". > " Interface: $ifc \n". > " Screen: $scr \n". > "Description: $desc \n"); > mysql_free_result($result); > } > > > The E-mail that is sent looks like this: > > A New Issue Has Been Logged! > > Issue ID: > Logged By: > Remote Host: 20x.2x.xxx.xxx > Log Date: > Priority: > Interface: > Screen: > Description: > > > > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > --

« previous php.db (#20635) next »