Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

printing out mysql query 1

Status
Not open for further replies.

captlid

Technical User
Oct 27, 2004
82
US
say theres a query
mysql_query("select * from table where id ='$id'");
how can I print out the query statement? i.e...
select * from table where id = 3

thanks
 
For debugging, I do something like this:

$query = "select * from table where id ='$id'";
echo "$query\n<br />";
mysql_query($query);
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top