If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > jcc cann't create trigger

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-06-10, 02:43
zq111 zq111 is offline
Registered User
 
Join Date: Sep 2010
Posts: 2
jcc cann't create trigger

This SQL "CREATE TRIGGER b_new_file_dbr_dsf AFTER insert ON ADMINISTRATOR.TABLE1 REFERENCING NEW AS NEW FOR EACH ROW BEGIN ATOMIC insert into table3 values(1); END;"
Iam getting this errror while using jcc connectivity.
---------------------------------------------------
Caused by: com.ibm.db2.jcc.am.vo: DB2 SQL Error: SQLCODE=-104, SQLSTATE=42601, SQLERRMC=;;able3 values(1); END;END-OF-STATEMENT, DRIVER=4.8.87

But in TODA,it runs well
Reply With Quote
  #2 (permalink)  
Old 09-07-10, 08:10
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
I do not know if this will fix it, but remove the semicolon after END.

Andy
Reply With Quote
  #3 (permalink)  
Old 09-07-10, 22:08
zq111 zq111 is offline
Registered User
 
Join Date: Sep 2010
Posts: 2
thank you for your reply

I removed that semicolon ,Then the SQL can run in JDBC
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On