Answers for "sql common columns"

SQL
0

sql common columns

-- NB: Applicable for Oracle and PL/SQL only

select * 
from all_tab_cols A
where 
   A.COLUMN_NAME in 
   (
      select B.column_name
      from all_tab_cols B
      where B.table_name = 'YourFirstTable'
   )
   and A.table_name != 'YourFirstTable'
   and A.TABLE_NAME = 'YourSecondTable';
Posted by: Guest on October-12-2020

Code answers related to "sql common columns"

Code answers related to "SQL"

Browse Popular Code Answers by Language