I am running version 4.1.1a of MySQL server, and I am running into a problem. The below SQL query causes an error, saying:
[MySQL][ODBC 3.51 Driver][mysqld-4.1.1a-alpha-nt]Every derived table must have it's own alias
I have looked at this query up and down and can't find anything wrong with it. I did find somewhere that there is possibly a bug with MySQL and this issue? But according to what I read, it had already been fixed in this version? Is the probem with my code, or is it a bug in the MySQL version that I have? Help!!!
[MySQL][ODBC 3.51 Driver][mysqld-4.1.1a-alpha-nt]Every derived table must have it's own alias
I have looked at this query up and down and can't find anything wrong with it. I did find somewhere that there is possibly a bug with MySQL and this issue? But according to what I read, it had already been fixed in this version? Is the probem with my code, or is it a bug in the MySQL version that I have? Help!!!
Code:
SELECT
T1.USR_ID,
T1.USR_NM,
T1.EMAIL_FRMT
FROM
(
SELECT * FROM
(
SELECT DISTINCT
INNER1.USR_ID,
INNER1.USR_NM
FROM
DB2_SPARKS_USRS INNER1,
DB2_SPARKS_MATCHES INNER3
WHERE
INNER3.USR_ID = 1879487720 AND
INNER3.MATCH_USR_ID = INNER1.USR_ID
)
UNION
(
SELECT DISTINCT
INNER1.USR_ID,
INNER1.USR_NM
FROM
DB2_SPARKS_USRS INNER1,
DB2_SPARKS_MATCHES INNER3
WHERE
INNER3.MATCH_USR_ID = 1879487720 AND
INNER3.USR_ID = INNER1.USR_ID AND
)
) T1
ORDER BY T1.USR_NM