Answer the question
In order to leave comments, you need to log in
SQL query: how to make a selection from two databases by mismatches?
There are two bases, the number of rows is the same. How to select rows with three matching elements (full name) from both bases and leave only those in which the fourth element (ID) differ?
ps
Urgently needed in the work, I know the .SQL query language at the initial level of select-from-where.
Answer the question
In order to leave comments, you need to log in
select * from db1.table t1
inner join db2.table t2
on t1.f = t2.f
and t1.i = t2.i
and t1.o = t2.o
and t1.id != t2.id
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question