Create a table with all the columns of inner join of two other tables without copying data I have two tables Table1 and Table2 with 10,000 and 15,000 rows each. I want to create a table Table3 that can contain all the data of inner join of Table1 and Table2, yet is empty. I tried something like this:

CREATE TABLE Table3
(LIKE Table1 INNER JOIN Table2 ON Table1.col11 = Table2.col21);


What is the best solution I can have?
CREATE TABLE your_table AS your_select WITH NO DATA;


https://www.postgresql.org/docs/current/static/sql-createtableas.html