Subject Re: Install Problems and After Install Problems
Author trac_t2000
I checked the creation order in the data module. The IB_Connection
is well after the TDatabase. And any IBO component is created after
the IB_Connection. So I am pretty sure that is not it. I also made
sure that no IB queries were trying to run before the handle was
shared. I even made sure there are not BDE queries opening before
the handle is shared.

Last I added a IB_Session to the datamodule. I moved it to the first
item in the creation order. I still get the same error.

Any other thoughts?

--- In, Helen Borrie <helebor@...> wrote:
> At 07:54 AM 2/04/2006, you wrote:
> >I checked the creation order. Both TDatabase and the IB_Connection
> >in a datamodule. Not sure how to check the real creation order,
> >the TDatabase is the 2 item listed in the dfm.
> You need to set the creation order in the form or datamodule. The
> order of appearance in the DFM has nothing to do with it - the DFM
> just a "telephone book" that the compiler looks up when it wants to
> find out the attributes of an object. This is basic Delphi
> stuff! Right-click on the form or datamodule, select Creation
> order.. and then use the arrow control to move the non-visual
> components into the order you want them created.
> >Also, just to make sure, I freed the IB_Connection and recreated
> >but I still get the same error. I also made sure that nothing was
> >trying to use this connection yet. I have a tool to show the
> >function calls. I have pasted that below... The top line is where
> >the error was thrown from.
> It doesn't show anything about the creation of the dbhandle. Also,
> disconnecting from a shared handle (if it exists) WILL give you an
> if you already disconnected from the TDatabase. And calling
> Disconnect from a tib_connection to a shared handle doesn't close
> connection that it is sharing with the TDatabase. If you
> the TDatabase and then later try to reference the associated
> dbhandle, you will get an AV from trying to access dereferenced
> >I even tried to connect the IBO connection..Disconnect then assign
> >the db handle. That does not seem to work as well.
> >
> >I did try to connect then disconnect, then assign the dbhandle. I
> >did not see an error there, but it seems to error now on any bde
> >queries that I try to open. So at first I thought I had found a
> >solution, but it seems I am still stuck....
> Yep. Go back to the creation order and attend to that. Besides
> paying attention to the creation order of the two database
> connections, ALSO look at your statement objects. Make sure that
> queries are referencing higher objects that are not yet created.
> look at your code and your interface, and make sure you have no
> places where references are being made to a dbhandle that may not
> Tip: it may help if you create an explicit TIB_Session and make
> the very first object in the creation order.
> And don't overlook the fact that, although you have two connections
> sharing the same database handle, each connection is running in its
> own transactions. You will get AVs if you try to reference things
> one transaction from a different transaction.
> Helen