문제

if you are running a query that inserts a new set of records in a table from other one, there is a way to force the update of the coincident pk record in the destination table, without deleting records or split the process in two others (insert new and update existing)?

도움이 되었습니까?

해결책

In Firebird 2.1, you can do Update or Insert

UPDATE OR INSERT INTO T1 (F1, F2)
    VALUES (:F1, :F2)
    MATCHING (F1);
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top