mysql> create table temp_table_name ( test varchar(4) ); Query OK, 0 rows affected (0.00 sec) mysql> select temp_table_name.*, coordsys.* from coordsys left outer join temp_table_name on temp_table_name.test = coordsys.id_coordsys; +------+-------------+--------------------------------+ | test | ID_COORDSYS | COORDSYS_NAME | +------+-------------+--------------------------------+ | NULL | 1 | Solar Disc | | NULL | 2 | Heliographic | | NULL | 3 | Heliocentric Ecliptic | | NULL | 4 | Geocentric Inertial | | NULL | 5 | Geocentric Solar Magnetosferic | | NULL | 6 | Galactic | | NULL | 7 | SOHOcentric Ecliptic | | NULL | 10 | SDC | | NULL | 11 | Solar Disc Polar | | NULL | 12 | N/A | | NULL | 13 | Solar Cropped | +------+-------------+--------------------------------+ 11 rows in set (0.00 sec)