Jump to content

Archived

This topic is now archived and is closed to further replies.

steelmanronald06

Quick Question

Recommended Posts

Yeah, I rarely ever post for help but here I am. I don't mess much with mysql queries, I perfer ADODB, but I have a damn mysql query.

[code]
$get_forumers_online = mysql_query("SELECT * FROM forum_members WHERE lastLogin < 15 MINUTES");
$num_forumers_online = mysql_num_rows($get_forumers_online);
echo "Total Online: $num_forumers_online <br />";
[/code]


[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'MINUTES' at line 1
[/quote]

Share this post


Link to post
Share on other sites
its picky on single and doule quote
[code]
$get_forumers_online = mysql_query("SELECT * FROM forum_members WHERE lastLogin < '15 MINUTES'");

[/code]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.