select id, hid, name,duty, tel1, email from(
select id , hid, name AS name, duty, tel1, a_email AS email from
T_ORG_a
union all
select id, hid, pro_name As name, pro_lv, pro_tel1, pro_email AS
email from T_SUBJECT_A)
union all
select id, hid, name, sub_tel, sub_fax, sub_email from
T_SUBJECT
------------------------------------------------------------------------------
새개의 테이블(T_ORG_a, T_SUBJECT_A, T_SUBJECT)을 조인한후에
이름으로 검색을 해보면 같은 이름이 2, 3번 반복해서 나옵니다..
한번만 나오게 할수는 없는지.. 답변 부탁드립니다..
|