Hello
I am trying to make a emailudf show in db2mag set 2000 to work with my database.
first i try build a trigger show above
// Create the emailUDF Trigger
public static void
registerTrigger (Connection con) throws Exception
{ try
{ Statement registerStmt = con.createStatement ();
System.out.println (" Registering Java trigger: AC");
registerStmt.executeUpdate (
" CREATE TRIGGER CONTATOS.AC " +
" AFTER INSERT ON CONTATOS " +
" REFERENCING NEW AS N_ROW " +
" FOR EACH ROW MODE DB2SQL " +
" BEGIN ATOMIC " +
" VALUES (EMAILUDF (N_ROW.RECEIVER,
N_ROW.SUBJECT,
N_ROW.MESSAGE) ); " +
" END ");
}.
but when i try this
I receve the same erros outut
----------------------------- Command Entered ------------------------------
// Create the emailUDF Trigger
public static void
registerTrigger (Connection con) throws Exception
{ try
{ Statement registerStmt = con.createStatement () ;
-----------------------------------------------------------------------------
DB21034E The command was processed as an SQL statement because it was not
a valid Command Line Processor command. During SQL processing it returned:

SQL0007N The character "{" following "on) throws Exception" is not valid.


SQLSTATE=42601

Where i am wrong ?

I try this ( http://www.db2mag.com/db_area/archiv...4/cutlip.shtml)