![]() | ![]() Products ![]() ![]() ![]() ![]() |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 6 of 6 total |
![]() |
Sat, Jun 14 2008 2:00 AM | Permanent Link |
Abdulaziz Jasser | I am trying to create a trigger use the following script but I got error when trying to execute it (line 4 column 16):
CREATE TRIGGER "AccountUpdate" AFTER UPDATE OF "AccountNo" ON "TB_AccountsChart" BEGIN INSERT INTO TB_Log (Form_Name) VALUES (NEWROW.AccountNo); END |
Sat, Jun 14 2008 3:06 AM | Permanent Link |
ulibecker | Abdulaziz,
<< CREATE TRIGGER "AccountUpdate" AFTER UPDATE OF "AccountNo" ON "TB_AccountsChart" BEGIN INSERT INTO TB_Log (Form_Name) VALUES (NEWROW.AccountNo); END >> try Execute Immediate 'INSERT INTO TB_Log (Form_Name) VALUES (' + Cast(NEWROW.AccountNo as VarChar) + ')'; Untested. Uli |
Sat, Jun 14 2008 3:06 PM | Permanent Link |
Abdulaziz Jasser | Uli
<<try Execute Immediate 'INSERT INTO TB_Log (Form_Name) VALUES (' + Cast(NEWROW.AccountNo as VarChar) + ')'; Untested.>> Sorry, but does not work. I still get an error. |
Sat, Jun 14 2008 3:10 PM | Permanent Link |
Fernando Dias ![]() | Abdulaziz,
It's very difficult to help you if you don't tell us at least what error do you get and what EDB version are you using... -- Fernando Dias [Team Elevate] |
Sun, Jun 15 2008 12:27 AM | Permanent Link |
"Raul" | Try following as body of the trigger :
BEGIN DECLARE st STATEMENT; PREPARE st FROM 'insert into TB_LOG (FORM_NAME) VALUES (?)'; EXECUTE st USING NEWROW.AccountNo; END Raul "Abdulaziz Jasser" <jasser@cyberia.net.sa> wrote in message news:19440235-373A-4FF7-85B8-A474521F918D@news.elevatesoft.com... >I am trying to create a trigger use the following script but I got error >when trying to execute it (line 4 column 16): > > > CREATE TRIGGER "AccountUpdate" AFTER UPDATE OF "AccountNo" > ON "TB_AccountsChart" > BEGIN > INSERT INTO TB_Log (Form_Name) VALUES (NEWROW.AccountNo); > END > |
Sun, Jun 15 2008 4:24 PM | Permanent Link |
Abdulaziz Jasser | Raul,
<<Try following as body of the trigger : BEGIN DECLARE st STATEMENT; PREPARE st FROM 'insert into TB_LOG (FORM_NAME) VALUES (?)'; EXECUTE st USING NEWROW.AccountNo; END>> Thanks now it works. |
This web page was last updated on Wednesday, August 14, 2024 at 03:12 PM | Privacy Policy![]() © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? ![]() |