Wednesday , April 2 2025

Set Tablespace As Default In Postgresql

In today’s article, we will discuss how to change the default Tablespace in PostgreSQL. If you do not specify a different Tablespace when creating objects, PostgreSQL will, by default, create them in the pg_default Tablespace.

If you want to change this, you can use the following parameter.

After connecting to Postgresql;

SET default_tablespace= createdTableSpaceName;

Ex:

Loading

About Faruk Erdem

Leave a Reply

Your email address will not be published. Required fields are marked *