Re: TADOConnection and Oracle
- From: "Mick Board" <mick_board@xxxxxxxxx>
- Date: Thu, 26 Oct 2006 11:34:45 +1000
Resolved. I need to have a 2nd .udl file that exists, but doesn't connect
to anything. Set the connection object to point to it, wait for the
timeout, connect to the original .udl file and it behaves correctly.
"Mick Board" <mick_board@xxxxxxxxx> wrote in message
news:453f4976@xxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
I'm finding an interesting problem when using a TADOConnection connected
to an Oracle database with both the Microsoft Oracle Driver or Oracle's
Oracle driver. (I'm using MDAC 2.8). I'm writing some software that's
dependent on handling if the database goes down. On shutting down the
database for testing purposes I'm finding that I can trap an error
occuring when I try and run a TADOQuery that's using the TADOConnection
to connect, however the TADOConnection object, always tells me it's
connected - even if I close it's connection and open it again!! The
problem with this is a) the database is down, b) if I bring the database
up again, try connecting again (yes - successful again), try closing and
running the TADOQuery based off this connection - the query fails. For
some reason the TADOConnection object isn't giving an error when it's
being closed then opened again on the shutdown database.
Now: I can do the above against SQL Server database and it works
correctly. i.e. If I disconnect and reconnect the TADOConnection object
when the SQL Server database is down it tells me accordingly. When it
comes up again, I can run code to connect the TADOConnection properly and
the TADOQuery that uses this then works again (after its opened again).
Any thoughts on how I can get this to work for Oracle. This is driving me
crazy!
.
- References:
- TADOConnection and Oracle
- From: Mick Board
- TADOConnection and Oracle
- Prev by Date: TADOConnection and Oracle
- Next by Date: Order of records in a table? Db corrupt?
- Previous by thread: TADOConnection and Oracle
- Next by thread: Order of records in a table? Db corrupt?
- Index(es):
Relevant Pages
|