Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hkrHq-0001ZV-P3 for pgsql-bugs@arkaria.postgresql.org; Tue, 09 Jul 2019 14:40:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hkrHo-0001rD-MK for pgsql-bugs@arkaria.postgresql.org; Tue, 09 Jul 2019 14:40:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hkrHo-0001r6-EJ for pgsql-bugs@lists.postgresql.org; Tue, 09 Jul 2019 14:40:04 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hkrHh-0007fv-Qk for pgsql-bugs@lists.postgresql.org; Tue, 09 Jul 2019 14:40:03 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x69EdtcS021983; Tue, 9 Jul 2019 10:39:55 -0400 From: Tom Lane To: ishanjoshi@live.com cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #15901: Tablespace showing as null in psql and pgadmin In-reply-to: <15901-e5cfe2dd7298a3a4@postgresql.org> References: <15901-e5cfe2dd7298a3a4@postgresql.org> Comments: In-reply-to PG Bug reporting form message dated "Tue, 09 Jul 2019 09:14:49 -0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <21981.1562683195.1@sss.pgh.pa.us> Date: Tue, 09 Jul 2019 10:39:55 -0400 Message-ID: <21982.1562683195@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk PG Bug reporting form writes: > As I have created separate tablespace (Not using default tablespace > pg_default or pg_global) for my new database. I have tried to create tables > with and without tablespace parameter and both these tables while checking > in pg_table, tablespace column showing as null. I tried to extract from > other tables but getting tablespace as null only. The case you showed isn't a bug: creating a table that's specified to be in the database's default tablespace is treated the same as not specifying any tablespace. This is because if you change the database's default tablespace later, such a table will be moved along with every other table that's in the database's default tablespace. regards, tom lane