MySQL Forums
Forum List  »  PHP

Query issue (MySQL 4.1.9 => MySQL 3.23.39.01)
Posted by: Big Foot
Date: March 28, 2006 03:43AM

Hi,

I have develop a PHP/MySQL application with MySQL 4.1.9 but it appears that the target MySQL version is 3.23.39.01.

And with this old version of MySQL, a query (which was correct on 4.1.9) return an error.

Here are the query and the error:

SELECT d.dealid, d.vermaj, MAX( d.vermin ) AS vermin
FROM dealversion AS d, (
SELECT dealid, MAX( vermaj ) AS vermaj
FROM dealversion
GROUP BY dealid
) AS t
WHERE d.dealid = t.dealid
AND d.vermaj = t.vermaj
GROUP BY d.dealid

#1064 - You have an error in your SQL syntax near '( SELECT dealid, MAX(vermaj) AS vermaj FROM dealversion GROUP BY dealid ) AS t W' at line 1

I MUST make a query correct for MySQL 3.23.39.01 but I can't find out how I can solve this problem...

I hope someone will be able to help me :(

Options: ReplyQuote


Subject
Written By
Posted
Query issue (MySQL 4.1.9 => MySQL 3.23.39.01)
March 28, 2006 03:43AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.