Thread: database information
how do i get the names of the databases that are created in postgres? is there a select statement similar to oracle? peter choe
SELECT datname FROM pg_database WHERE datname NOT LIKE 'template_'; -r At 04:22 PM 7/30/01 -0400, Peter Choe wrote: >how do i get the names of the databases that are created in postgres? > >is there a select statement similar to oracle? > >peter choe > >---------------------------(end of broadcast)--------------------------- >TIP 4: Don't 'kill -9' the postmaster > > > >--- >Incoming mail is certified Virus Free. >Checked by AVG anti-virus system (http://www.grisoft.com). >Version: 6.0.251 / Virus Database: 124 - Release Date: 4/26/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.251 / Virus Database: 124 - Release Date: 4/26/01
\l will do On Mon, Jul 30, 2001 at 04:22:24PM -0400, Peter Choe wrote: > how do i get the names of the databases that are created in postgres? > > is there a select statement similar to oracle? > > peter choe > > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster
On Mon, 30 Jul 2001 20:28:32 +0000 (UTC), Peter Choe <choepete@mindspring.com>: > how do i get the names of the databases that are created in postgres? > From psql: \l (also, see \? for additional handy tools) or, from your shell: psql -l