Jump to content

MySQL version problems


dtgreenwood

Recommended Posts

Hello everyone.
After heading over to mysqlfreaks for help and finding the forums shut down :( I've been redirected over here.

I'm having a problem with MySQL versions. I run MySQL 5.0.21-community-nt on my localhost for development and my web sites server runs MySQL 3.23.58. Until now this hasn't been a problem.

Having used the following SQL statement on my localhost and having it return correct results.[code]SELECT distinct a.articleid, a.articleauthorid, a.articletitle, a.articlecontent, a.articledate, a.articleenclosuretitle, a.articleenclosureuri, a.articleenclosurelength, u.userid, u.username, u.userstatus, (SELECT COUNT(*) FROM comments WHERE comments.articleid = a.articleid)AS articlecomments FROM comments c, articles a, users u WHERE a.articleauthorid = u.userid ORDER BY articledate DESC LIMIT 0,3[/code] I updated my website to use the new SQL with no luck. My web site's MySQL server gives me the following error: [code]#1064 - You have an error in your SQL syntax near 'SELECT COUNT(*) FROM comments WHERE comments.articleid = a.articleid) AS articlec' at line 1[/code]

My question is how would I replicate the same results of the above statement for my web sites server?

If anymore information is required just let me know. Thanks in advance.
dtgreenwood.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

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.