Skip to content
Advertisement

SQL query to find distinct values in two tables?

I would like to find the distinct Code values and get a return like this:

I can’t figure out how to write a SQL query that would return me the above results. Anyone have any experience with a query like this or similar?

Advertisement

Answer

In proper RDBMS:

In MySQL… the UNION removes duplicates

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement