We help IT Professionals succeed at work.
Get Started

PHP echo sql result

Last Modified: 2013-12-12
I'm not able to get the result of the second query $Result to echo out, what am I missing?

Thanks in advance

$sqlstr = mysql_query("SELECT * FROM Roster");

$Result = mysql_query("Select Count(*) AS 1stMain from Race_Results where `1` = ".$row['Car_Number']."");

echo "<table border=0 align='center'>";
echo "</td><td rowspan=8>";
echo $row['Image'];
echo "</td><th width=300>";
echo "<u>Details</u>";
echo "</th>";
echo "<th width=300>";
echo "<u>YTD Stats</u>";
echo "</th>";
echo "<th width=300>";
echo "<u>Overall Stats</u>";
echo "</th></tr><tr><td>";
echo "<b>Car Number: </b>" .$row['Car_Number'];
echo "</td><td>";
echo "<b>1st in Main: </b>" .$Result;
echo "</td><td>";
echo "<b>1st in Main: </b>";

Open in new window

Watch Question
Software Architect
Top Expert 2010
This problem has been solved!
Unlock 2 Answers and 8 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE