pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Dave Cramer <pg@fastcrypt.com>
To: Nidhi Srivastava <nsrivastava@quark.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Create Database using JDBC
Date: Fri, 1 Jul 2005 08:30:21 -0400
Message-ID: <01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com> (raw)
In-Reply-To: <2BC68159E3EC814BA1E81C108DF99A4203A37FD9@EXCH-IND-VS1.india.quark.com>
References: <2BC68159E3EC814BA1E81C108DF99A4203A37FD9@EXCH-IND-VS1.india.quark.com>

Is it possible you have an existing open transaction on template1 ?

Have a look at the postgresql logs.

Dave
On 1-Jul-05, at 4:30 AM, Nidhi Srivastava wrote:

> Hi all
>
>
>
> I wish to create a database if one doesn’t exist using JDBC. I  
> tried connecting to template1 database and then issuing the “CREATE  
> DATABASE test” command but I get the following error :
>
>
>
> ERROR:  CREATE DATABASE: source database "template1"
> is being accessed by other users
>
>
>
>
> How do I resolve this? I’m using PostGreSQL8.0
>
>
>
> Thanks & Regards
>
> Nidhi
>
>



Dave Cramer
davec@postgresintl.com
www.postgresintl.com
ICQ #14675561
jabber davecramer@jabber.org
ph (519 939 0336 )

view thread (20+ messages)  latest in thread

Message-ID: <01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com>
Permalink:  ../01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com/
Also on:    postgresql.org/message-id/01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: pg@fastcrypt.com, nsrivastava@quark.com
  Subject: Re: Create Database using JDBC
  In-Reply-To: <01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com>
  References: <2BC68159E3EC814BA1E81C108DF99A4203A37FD9@EXCH-IND-VS1.india.quark.com> <01D427A8-9B3A-457E-8371-C1BA62416274@fastcrypt.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox