Thread: Re: [PATCHES] default database creation with initdb
> -----Original Message----- > From: Christopher Kings-Lynne [mailto:chriskl@familyhealth.com.au] > Sent: 21 June 2005 08:57 > To: Dave Page > Cc: Robert Treat; Tom Lane; Andrew Dunstan; Andreas Pflug; > Magnus Hagander; pgsql-hackers@postgresql.org > Subject: Re: [HACKERS] [PATCHES] default database creation with initdb > > > Yes - that's intentional so that pgAdmin/phpPgAdmin et al. can > > reasonably expect it to be there. > > Problem is, how the hell do I know it's there before I connect? Well obviously you don't (any more than you know that template1 is accessible until you try), but in time it will be on more and more systems as people upgrade by when it will make a reasonable default for clients. Alternatively, try to connect to it first, and then fall back to template1 (much as libpq negotiates protocol versions with the server). Regards, Dave
On Tuesday 21 June 2005 04:01, Dave Page wrote: > > -----Original Message----- > > From: Christopher Kings-Lynne [mailto:chriskl@familyhealth.com.au] > > Sent: 21 June 2005 08:57 > > To: Dave Page > > Cc: Robert Treat; Tom Lane; Andrew Dunstan; Andreas Pflug; > > Magnus Hagander; pgsql-hackers@postgresql.org > > Subject: Re: [HACKERS] [PATCHES] default database creation with initdb > > > > > Yes - that's intentional so that pgAdmin/phpPgAdmin et al. can > > > reasonably expect it to be there. > > > > Problem is, how the hell do I know it's there before I connect? > > Well obviously you don't (any more than you know that template1 is > accessible until you try), but in time it will be on more and more > systems as people upgrade by when it will make a reasonable default for > clients. > > Alternatively, try to connect to it first, and then fall back to > template1 (much as libpq negotiates protocol versions with the server). > You know, since we don't maintain static connections (http is our friend) connecting to template1 really isn't a problem for phppgadmin users. At least I can't remember anyone ever having complained about it. -- Robert Treat Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL
Robert Treat <xzilla@users.sourceforge.net> writes: > You know, since we don't maintain static connections (http is our friend) > connecting to template1 really isn't a problem for phppgadmin users. At > least I can't remember anyone ever having complained about it. Sure you have: people have complained about CREATE DATABASE failing with "source database "template1" is being accessed by other users" often enough. regards, tom lane
Tom Lane wrote: >Robert Treat <xzilla@users.sourceforge.net> writes: > > >>You know, since we don't maintain static connections (http is our friend) >>connecting to template1 really isn't a problem for phppgadmin users. At >>least I can't remember anyone ever having complained about it. >> >> > >Sure you have: people have complained about CREATE DATABASE failing with >"source database "template1" is being accessed by other users" often >enough. > > > > And other GUIs certainly do keep nailed up connections. cheers andrew
On Tuesday 21 June 2005 10:04, Tom Lane wrote: > Robert Treat <xzilla@users.sourceforge.net> writes: > > You know, since we don't maintain static connections (http is our friend) > > connecting to template1 really isn't a problem for phppgadmin users. At > > least I can't remember anyone ever having complained about it. > > Sure you have: people have complained about CREATE DATABASE failing with > "source database "template1" is being accessed by other users" often > enough. > I meant wrt phppgadmin.... for us theres no real need to change the default connection. obviously others will differ. -- Robert Treat Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL