I have a application which uses Firebird (Version 2.5) database. I wanted to trigger one of the table entry to another database table which is in SQL Server 2008 R2. When I commit I am getting this following error
ErrorCode: 335544569 (ErrorMessage: Dynamic SQL Error SQL error code = -104).
Code:
CREATE TRIGGER "trig_INV"
FOR "INVA"
ACTIVE
AFTER UPDATE
POSITION 100
AS
BEGIN
IF ((updating) AND ((old.cold <> new.cold))) THEN
BEGIN
INSERT INTO 192.168.17.206/1043: [RBT].[dbo].[N_Inv]([COLA], [COLB], [COLC], [COLD], [COLD], [COLE])
SELECT FIRST 1
"COLA", "COLB", "COLC", "COLD", "COLE"
FROM "INVA"
ORDER BY COLA DESC
END
I am not sure firebird trigger allow to push records to a SQL Server database. It will be great if anyone has tried such and provide some reference. Thanks in advance.
UDF) which you would call from the trigger and which will use some external means to communicate with SQL server, this approach potentially has the least latency, but can crash Firebird server (if you make mistakes in DLL, of if your DLL can freeze work for significant time) and would probably be removed in FB4. Better approach would be toPOST_EVENTand to have a separate syncronizing applicaiton, which sits connected to both the Firebird and MS-SQL waiting for the FB event, and when it gets it - it scans FB DB for changes and pump them into MS SQL. - Arioch 'The