Jump to content

MySQL 4.1 to 5.0 issue


Silverado_NL

Recommended Posts

hi everybody, i always come here when im in trouble, and it has been a long while ago.

anyways i just upgraded to Mysql v5.0 and now a query isnt working.

i had other problems with the upgrade and managed to circumvent them, its just this issue i cant solve.

does anybody else know what is wrong???

 

 

this is the error on the web page

--------------------------------------------------------------------------------------------------------------------------------

SELECT DISTINCT cp.channel_productdata_id, cp.partner_product_id, cp.medium_id, cp.image, cp.beschrijving,cp.actief, cp.homepage, product.product_id, product.product_naam, merk.naam as merk, product.actief as product_actief, product.klein_image FROM channel_productdata AS cp INNER JOIN partner_product ON partner_product.partner_product_id=cp.partner_product_id INNER JOIN product ON product.product_id=partner_product.product_id INNER JOIN merk ON merk.merk_id=product.merk_id WHERE cp.partner_channel_id='51' ORDER BY channel_productdata_id DESC AND cp.channelHomepage='1' LIMIT 1

 

Query error 1064: 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 'AND cp.channelHomepage='1' LIMIT 1' at line 7

--------------------------------------------------------------------------------------------------------------------------------

 

this is the actual query

 

--------------------------------------------------------------------------------------------------------------------------------

 

$productset_query = "SELECT DISTINCT cp.channel_productdata_id, cp.partner_product_id, cp.medium_id, cp.image, cp.beschrijving,cp.actief, cp.homepage, product.product_id, product.product_naam, merk.naam as merk, product.actief as product_actief, product.klein_image FROM channel_productdata AS cp INNER JOIN partner_product ON partner_product.partner_product_id=cp.partner_product_id INNER JOIN product ON product.product_id=partner_product.product_id INNER JOIN merk ON merk.merk_id=product.merk_id WHERE cp.partner_channel_id='".$partner_channel_id."' ORDER BY channel_productdata_id DESC ".$top.$lim;

 

--------------------------------------------------------------------------------------------------------------------------------

 

if anybody could help me i would be eternaly greatfull, this is a pretty important query to me.

 

thanx in advance.

 

 

greetings

 

 

Silverado

 

btw ill be posting fulltime again since i have internet @ home again:)

Link to comment
Share on other sites

oh yeah and by the way where the heck is the solve button?

i started this post so i should be able to solve it right?

cause i can see a post thats solved, so i guess it has been enabled now since my last visit?

if anybody could tell me this i would be very gratefull en the board will have more space for more important things:)

 

 

 

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.