Re: Create Database using JDBC

From: Thomas Dudziak <tomdzk(at)gmail(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Create Database using JDBC
Date: 2005-07-04 16:24:49
Message-ID: 224f323405070409241a7edd67@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On 7/4/05, Nidhi Srivastava <nsrivastava(at)quark(dot)com> wrote:
> Problem is if any client application is connected to another database on
> my server anywhere, I shall not able to create my database using
> template1. How can I determine which other clients are connected to my
> server?

Have you tried that this doesn't work ? If none of the clients is
connected to template1 but only to their own databases, then AFAIK it
should work (pgAdmin might be different in this matter, perhaps it is
always connected to the template databases ?).
You could write a small JDBC app to verify that it does/doesn't work, eg.

* open a connection to template1
* create database test
* close connection to template1
* open connection to test and keep it open
* open connection to template1
* create database test2
* close connection to template1
* close connection to test

if this doesn't work, then you probably should file a bug and attach
this sample app.

Tom

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Dave Cramer 2005-07-04 19:02:35 Re: Create Database using JDBC
Previous Message Nidhi Srivastava 2005-07-04 13:08:36 Re: Create Database using JDBC