1.
SELECT DISTINCT(detail.detail_id) detail.id_detail, detail.ThaiName, detail.EngName, tel.id_tel, fax.fax, contact.con_name, contact.c_name, contact.c_lastname, contact_tel.c_tel
2.
FROM detail INNER JOIN
3.
contact ON detail.id_detail = contact.id_detail INNER JOIN
4.
contact_tel ON contact.id_con = contact_tel.id_con INNER JOIN
5.
tel ON detail.id_detail = tel.id_detail INNER JOIN
6.
fax ON detail.id_detail = fax.id_detail
7.
WHERE (detail.Enable =
'T'
)