Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Stack Gives Back Safety in numbers: crowdsourcing data on nefarious IP addresses. Featured on Meta. React Native. Python Design Patterns. Python Pillow. Python Turtle. Verbal Ability.
Interview Questions. Company Questions. Artificial Intelligence. Cloud Computing. Connect and share knowledge within a single location that is structured and easy to search. I'm trying to get the second set of inserts, from the second system, to insert, and if duplicate, update instead. I can't seem to get it right. For the final insert, what should I have?
I don't have the "Filter Part" because I don't have the Table2 data inserted. The filter part would show rows where Active, Last or First name is different between the two systems. Note: I have this working with 2 temp tables created I'm just trying to get this to work in a manner I haven't used before.
You could write a SELECT statement that captures the id's that have been inserted from the first insert into the temp table. I could be wrong about that, because it's not completely clear to me that the ID numbers on the two tables are going to match. Sign up to join this community. The best answers are voted up and rise to the top. Silent Column Specification Changes. Secondary Indexes and Generated Columns. Data Manipulation Statements.
Parenthesized Query Expressions. The Subquery as Scalar Operand. Comparisons Using Subqueries. Restrictions on Subqueries. Transactional and Locking Statements. Statements That Cause an Implicit Commit. Restrictions on XA Transactions. Replication Statements. Functions which Configure the Source List.
0コメント