Subject Re: Re: [firebird-support] (Again!) AV when using events in FB15
Author joeny@e-webcore.net
Hi Helen,

> OK, provide "db" is set up as a path alias in aliases.conf. This I doubt
> from your description, since you didn't mention it.
>
> So this would not be a correct connection string. It should be either
> d:\path_to_database (for local connect)
> server:d:\path_to_database (for remote connect)
> or localhost:d:\path_to_database (for local loopback).

My apologies :) what I meant was the TCP/IP connection syntax.
In my test case, I connect using:

home:C:\Test\Sample.fdb

> No such problem with IBO, but I'm on Win2K, always connect to localhost or
> remote server and I do have a dedicated port for events. I suggest that,
> once you get your connection string sorted, you do the same thing.

I tried it (FIBPlus & FreeIBC) also on WinXP (not on Win2K though) and
still got AVs.

> I don't think events work with Windows local-connect AT ALL, since there is
> no TCP/IP port available with that protocol. (Events need their own port).

I tried the local connection string (ie. C:\Events\Sample.fdb) and I can
use events. Am I missing something?

Here is a more detailed explanation :)

1. I created a database via IBConsole:

CREATE DATABASE 'C:\Events\Sample.fdb' PAGE_SIZE 4096;

2. Using Delphi, I dropped a TFIBDatabase, TFIBTransaction, TFIBDataSet,
and an event alerter component, TFixedIBEventAlerter. (Or the
corresponding components in FIBPlus).

3. On TFIBDatabase's database path, I entered:

home:C:\Events\Sample.fdb

On TFIBDataSet's SQL property, I have

SELECT * FROM DUMMY;

On TFixedIBEventAlerter's list of events, I entered:

DUMMY

4. I linked the 4 components up and did the ff:

a. attach/open the database
b. start the transaction
c. open the TFIBDataSet (this will result in Table unkown error)
d. call TFixedIBEventAlerter.RegisterEvents
e. call TFixedIBEventAlerter.UnRegisterEvents
f. close the dataset (optional since it wasn't successfully opened)
g. rollback
h. close/detach database
---> AV on FBCLIENT.DLL

> helen

Thanks Helen :)

Joeny