sprint10s Posted March 9, 2010 Share Posted March 9, 2010 here is the error i get and below is the query on that line please help, am i missing a quote or something? Parse error: syntax error, unexpected ';' in /home/weiland2/public_html/standridgemotorsports.com/jeremy_schedule1.php on line 79 $result = mysql_query("SELECT *,DATE_FORMAT(h0237,\'%M %e %Y\') as dt FROM jos_jforms_72563 WHERE uid = 63 ORDER BY h0237 ASC"; Link to comment https://forums.phpfreaks.com/topic/194643-parse-error-query/ Share on other sites More sharing options...
aeroswat Posted March 9, 2010 Share Posted March 9, 2010 here is the error i get and below is the query on that line please help, am i missing a quote or something? Parse error: syntax error, unexpected ';' in /home/weiland2/public_html/standridgemotorsports.com/jeremy_schedule1.php on line 79 $result = mysql_query("SELECT *,DATE_FORMAT(h0237,\'%M %e %Y\') as dt FROM jos_jforms_72563 WHERE uid = 63 ORDER BY h0237 ASC"; you are missing a ) at the end of the query Link to comment https://forums.phpfreaks.com/topic/194643-parse-error-query/#findComment-1023664 Share on other sites More sharing options...
sprint10s Posted March 9, 2010 Author Share Posted March 9, 2010 that fixed that then i get this error Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/weiland2/public_html/standridgemotorsports.com/jeremy_schedule1.php on line 90 line 90 is in marked //$result = mysql_query("SELECT *, DATE_FORMAT(h0237,"%M %e %Y") FROM jos_jforms_72563 WHERE uid = 63 ORDER BY h0237 ASC "); $result = mysql_query("SELECT *,DATE_FORMAT(h0237,\'%M %e %Y\') as dt FROM jos_jforms_72563 WHERE uid = 63 ORDER BY h0237 ASC"); echo "<table align='center' border='1'> <tr> <th>Date</th> <th>Track</th> <th>Description</th> <th>Special Show</th> <th>Race Type</th> </tr>"; while($row = mysql_fetch_array($result)) //line 90 { echo "<tr>"; echo "<td>" . $row['h0237'] . "</td>";//Date echo "<td>" . $row['h9ca9'] . "</td>";//Track echo "<td>" . $row['hf6a6'] . "</td>";//Description echo "<td>" . $row['h67d6'] . "</td>";//Special Show echo "<td>" . $row['heb76'] . "</td>";//Race Type echo "</tr>"; } echo "</table>"; Link to comment https://forums.phpfreaks.com/topic/194643-parse-error-query/#findComment-1023669 Share on other sites More sharing options...
aeroswat Posted March 9, 2010 Share Posted March 9, 2010 Firstly the backslashes are not necessary in your SQL query. They are single quotes surrounded by double quotes so they are fine. Link to comment https://forums.phpfreaks.com/topic/194643-parse-error-query/#findComment-1023672 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.