How to set tablespace for a specific table creation AS clause?, like:
CREATE TABLE [New Table] AS
TABLE [Old Table]
--WITH NO DATA
;
In which tablespace new table with/without data is created for this specific 'AS' clause?
In official documentation, have not found such case: https://www.postgresql.org/docs/current/sql-createtable.html , though it says:
Tablespaces
The PostgreSQL concept of tablespaces is not part of the standard. Hence, the clauses TABLESPACE and USING INDEX TABLESPACE are extensions.
So, please help me out, what is default tablespace will be used in such "AS" creation case of the table, and how to specify custom table space for this. By ALTER -ing created table?, like only:
ALTER TABLE [New Table]
SET TABLESPACE [Existing Tablespace];