How do you create an empty table from an existing table in SQL?

This will create the basic table and its fields, but not indexes, constraints or triggers.

SELECT * FROM INTO WHERE 1=2

Some databases have an SQL command or stored procedure for copying the complete table definition, but there is no consistency. e.g. MySQL
CREATE TABLE LIKE

To write a procedure in SQL to interrogate a table definition and then re-create it is possible but a lot of work and will be database specific as each database has unique features. There are probably examples on the web is you look.