2009-07-29 7 views
0

제 요구 사항은 표 1의 설명 필드를 concatinating하여 테이블 2와 3의 설명으로 업데이트하는 것입니다. 나는 아래 구조를 줄 것이다. 표 2 D 및 표 3 D다른 두 테이블의 필드를 사용하여 테이블을 업데이트하십시오.

+0

프렘를 concatinating와

표 --PAD 표 2 --- PD 표 3 --- AD

테이블 D는, 당신이 등 4 * 질문에, * 것 같다 이 문제는 * 똑같은 문제에 직면 해 있습니다. (1) : http://stackoverflow.com/questions/1204701/update-table-with-a-subquery-which-is-returning-more-than-one-row (2) : http : // stackoverflow.com/questions/1199733/getting-extrarows-after-joing-the-3-tables-using-left-join (3) : http://stackoverflow.com/questions/1198183/update-a- 다른 두 개의 테이블을 사용하는 테이블 사용하기 (4) : http://stackoverflow.com/questions/1204563/updating-row-with- 하위 쿼리 반환 행 여러 개 – Liao

답변

0
INSERT INTO Table1 (Description) 
    SELECT CONCAT(t2.Description, t3.Description) FROM Table2 t2, Table3 t3 
    ---- optional join here 
관련 문제