Re: Switching databases over JDBC/ODBC - Mailing list pgsql-general

From Scott Bailey
Subject Re: Switching databases over JDBC/ODBC
Date
Msg-id 4A20962A.9000705@comcast.net
Whole thread Raw
In response to Re: Switching databases over JDBC/ODBC  (John R Pierce <pierce@hogranch.com>)
Responses Re: Switching databases over JDBC/ODBC
List pgsql-general
John R Pierce wrote:
> Scott Bailey wrote:
>> Is there an equivalent to psql's \connect database or MySQL/MS SQL's use
>> database command that will work with JDBC? It doesn't seem like I should
>> need to drop the connection and establish a new one just to switch
>> databases.
>
>
> the \connect command disconnects from the current database, and connects
> to a new one, this causes a new postgres server process to be spawned to
> replace the one servicing the old connection.

Well at work we've got Oracle, MySQL, MS SQL and Postgres. So I
generally use Aqua Data Studio because it works with all of them. For
MySQL and MS SQL you register a single connection to the server and can
switch to any database. But with Postgres, you have to register a new
connection for every database because you can't switch once connected.

I just figured that if even Microsoft can do it, surely we can.

Scott

pgsql-general by date:

Previous
From: John R Pierce
Date:
Subject: Re: Switching databases over JDBC/ODBC
Next
From: Craig Ringer
Date:
Subject: Re: Debugger install