I have an access query that accesses to mysql table through odbc connection but I'm getting this error.
ODBC: Falló la llamada. [MySQL][ODBC 5.1 Driver][mysqld-5.5.21] 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 'UNION (SELECT
id
FROMtable2
)) UNION (SELECTid
FRO' at line 1 (#1064)
I'm using this access query.
SELECT id FROM table1
UNION
SELECT id FROM table2
UNION
SELECT id FROM table3
This query works in mysql and also if the tables are in access, but it doesn't work when I do the query in accesss through odbc to mysql tables.
Any idea what the problem is?