From: | Dave Cramer <Dave(at)micro-automation(dot)net> |
---|---|
To: | carl(at)zero-one(dot)co(dot)za |
Cc: | "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: SQL Sessions and the DROP DATABASE command |
Date: | 2003-03-06 13:42:08 |
Message-ID: | 1046958127.1192.9.camel@inspiron.cramers |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
Well, you could do it within java, but not through the jdbc interface.
ie execute a c/shell/whatever program which does it.
Dave
On Thu, 2003-03-06 at 08:39, Carl Olivier wrote:
> Hey.
>
> Thanks for the reply, although not what I wanted to hear ;)
>
> damn!
>
> so you mean that I cannot do this except on the actual machine or via a
> shell script with sufficient permissions?!?!
>
> Carl
>
> -----Original Message-----
> From: Dave Cramer [mailto:Dave(at)micro-automation(dot)net]
> Sent: 06 March 2003 03:34 PM
> To: carl(at)zero-one(dot)co(dot)za
> Cc: pgsql-jdbc(at)postgresql(dot)org
> Subject: Re: [JDBC] SQL Sessions and the DROP DATABASE command
>
>
> Carl,
>
> This is not possible through the jdbc interface.
>
> Dave
> On Thu, 2003-03-06 at 04:25, Carl Olivier wrote:
> > Greetings.
> >
> > I need to be able to call the DROP DATABASE database command via JDBC.
> >
> > Unfortunately I need to kill off any active connections to the
> > specified database before the DROP DATABASE command will work.
> >
> > Is there anyway from within a JDBC connection to say the template1
> > database as the superuser on a POSTGRESQL server to:
> >
> > 1. Determine what connections are open and active to a specified
> > database
> > 2. Kill ALL these sessions.
> >
> > Thank you in advance,
> >
> > Carl Olivier
> --
> Dave Cramer <Dave(at)micro-automation(dot)net>
--
Dave Cramer <Dave(at)micro-automation(dot)net>
From | Date | Subject | |
---|---|---|---|
Next Message | Dirk Bromberg | 2003-03-06 15:34:30 | Re: Postgres PooledConnection... |
Previous Message | Carl Olivier | 2003-03-06 13:39:03 | Re: SQL Sessions and the DROP DATABASE command |