Re: How to list all schema names inside a PostgreSQL database through SQL

From: Achilleas Mantzios <achill(at)matrix(dot)gatewaynet(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: How to list all schema names inside a PostgreSQL database through SQL
Date: 2012-11-15 12:43:12
Message-ID: 56381542.e0BhAetaZ2@smadev.internal.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Πεμ 15 Νοε 2012 20:31:05 Xiaobo Gu wrote:
> Hi,
>
> How can I list all schema names inside a PostgreSQL database through
> SQL, especially thoese without any objects created inside it.
>
>

1st solution :

select catalog_name,schema_name from information_schema.schemata ;

2nd solution :

select * from pg_namespace ;

> Regards,
>
> Xiaobo Gu
>
>
>
-
Achilleas Mantzios
IT DEPT

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message sk baji 2012-11-15 13:13:13 Re: How to list all schema names inside a PostgreSQL database through SQL
Previous Message Виктор Егоров 2012-11-15 12:41:15 Re: How to list all schema names inside a PostgreSQL database through SQL