Oracle
 sql >> Database >  >> RDS >> Oracle

Oracle:combina due tabelle con colonne diverse

Usando Union All e Null come una colonna diversa:

SELECT col_1, col_2, NULL as col_3, NULL as col_4,
       date_1, NULL as date_2
FROM table_1

Union All

SELECT NULL, NULL, col_3, col_4, NULL, date_2
FROM table_2