Subject Re: [Firebird-Architect] Fwd: Re: [] Re: Firebird database switch in same connection
Author Ivan Prenosil
Perhaps it is just my ignorance about java things, but ...
What is the difference between "database switch" and
"disconnect from one database / connect to another one" ?
Why should the later occupy more resources ?

Also, "switching connection in same connection" makes
as much sense to me as starting transaction inside transaction.

Ivan


----- Original Message -----
From: "p_kenzie" <p_kenzie@...>
To: <firebird-architect@yahoogroups.com>
Sent: Friday, October 01, 2004 11:33 AM
Subject: [Firebird-Architect] Fwd: Re: [] Re: Firebird database switch in same connection


>
> Hi,
>
> Below is the snippet of the post I mailed in Firebird-java,
>
> >I have got a DB connection to the Firebird server (super sever) ,
> >to the database say 'c:\temp\one.fdb'. Now I like to switch the
> >database to 'c:\temp\two.fdb' in the same connection ..
>
> > I tried like as in the below code snippet ,
>
>
> > Connection conn = fb.getConnection("c:\temp\one.fdb");
> > //do some operation
> > //commit
> > //then swith db
> > conn.setCatalog("c:/temp/two.fdb");
> > // I am not sure of catalog setting will work
>
>
> > but db switching like above failed
>
>
> Since in firebird DB switching is not supported in same connection.
> I need to create a one more connection with db "two.db". It will
> occupy additional resource in the sense of port , object , etc.
>
> Our concern is not about the performance but optimizing the usage of
> resources.
>
> If you agree with this kindly consider this as feature requirement,
> or if you have any other view share it with me ,
>
>
> with regards,
>
> Peter Kenzie