473,324 Members | 2,179 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

SQL0206N during create trigger...

Hey Gurus..I am trying to figures out where my syntax is incorrect in the following SQL to to create an after insert trigger... I am getting
SQL0206N "INSERTROW.MF_USERID" is not valid in the context where it is used. LINE NUMBER=1. SQLSTATE=42703

CREATE TRIGGER "O000634"."test_insert"
AFTER
INSERT
ON "O000634"."TMAX300_USER"
REFERENCING
NEW AS "insertrow"
FOR EACH ROW
MODE DB2SQL
BEGIN ATOMIC
insert into O000634.TMAX300_USER_HISTORY ("MF_USERID", "SEC_MF_IND", "NET_ID", "FIRST_NAME", "MIDDLE_NAME",
"LAST_NAME", "PHONE", "PHONE_EXT", "FAX", "EMAIL", "AGENCY", "BUREAU",
"OMBBRN", "ROOM", "ADDRESS_1", "ADDRESS_2", "CITY", "STATE", "ZIPCODE",
"USER_STATUS", "ADMIN_USER", "COMMENT", "SDATE", "STIME", "SUSER", "CDATE",
"CTIME", "CUSER", "APPUSER", "ACTION")
VALUES
(insertrow.MF_USERID, insertrow.SEC_MF_IND, insertrow.NET_ID, insertrow.FIRST_NAME, insertrow.MIDDLE_NAME,
insertrow.LAST_NAME, insertrow.PHONE, insertrow.PHONE_EXT, insertrow.FAX, insertrow.EMAIL, insertrow.AGENCY, insertrow.BUREAU,
insertrow.OMBBRN, insertrow.ROOM, insertrow.ADDRESS_1, insertrow.ADDRESS_2, insertrow.CITY, insertrow.STATE, insertrow.ZIPCODE,
insertrow.USER_STATUS, insertrow.ADMIN_USER, insertrow.COMMENT, insertrow.SDATE, insertrow.STIME, insertrow.SUSER, insertrow.CDATE,
insertrow.CTIME, insertrow.CUSER, insertrow.APPUSER, 'INSERT');
END;
May 9 '07 #1
2 2574
Herb
13
try taking the Quotes off of insertrow.
May 9 '07 #2
OK whew!!..that worked...I swear to god Quest put those quotes there...Thanks Herb!
May 9 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

17
by: los | last post by:
Hi, I'm trying to create a program similar to that of Google's desktop that will crawl through the hard drive and index files. I have written the program and as of now I just put the thread to...
1
by: Barbara Lindsey | last post by:
I am a postgres newbie. I am trying to create a trigger that will put a copy of a record into a backup table before update or delete. As I understand it, in order to do this I must have a...
3
by: Prince Kumar | last post by:
Hi All, I am trying to a get a trigger retrieved from Oracle to work on DB2 UDB 8.1. I am getting the following error when trying to create the trigger. How would I resolve this? create table...
1
by: Zri Man | last post by:
Procedure Get_RowCount works fine when called independently. When called from Another procedure it gives the following error. SQL0206N "C" is not valid in the context where it is used....
4
by: jefftyzzer | last post by:
Friends: I have a query similar in structure to the following: SELECT T1.IBMREQD FROM SYSIBM.SYSDUMMY1 T1 LEFT JOIN TABLE
1
DTV12345
by: DTV12345 | last post by:
Hello! I am attempting to create a query that calculates a time value from GMT to Pacific time. It is, of course, based on the calendar date that I will have to figure out whether or not...
0
by: Johnny Ocampo | last post by:
Hi, I'm trying to use Microsoft Query to read data from DB2. However, I'm getting the following error message: SQL0206N "BLOB" is not valid in the context where it is used. SQLSTATE=42703. ...
0
by: KiranKGone | last post by:
Hello All, I need to define a trigger for updating the multiple columns of a target table when an insert happens on a subject table. I have written the following trigger, however, getting the...
1
by: 7h0r | last post by:
When trying to insert this trigger: CREATE TRIGGER ad_des_part_jon AFTER DELETE ON DESIGJON.PART_LIST REFERENCING OLD AS o FOR EACH ROW mode db2sql UPDATE DEFINJON.PART_LIST A SET...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.