Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

what the hell is wrong with this script

Status
Not open for further replies.

MichaelJackson

Programmer
May 30, 2003
3
US
please let me know why it says script was executed with 0 errors and 1 compilation error.
--------------------------------------thanks

CREATE OR REPLACE TRIGGER trig_TACCT_ACCT AFTER DELETE OR INSERT OR UPDATE
ON TACCT_ACCT
REFERENCING OLD AS OLD
NEW AS NEW
FOR EACH ROW
DECLARE
temp_dml_type_code VARCHAR2(1);
BEGIN
IF UPDATING THEN
temp_dml_type_code := 'U';
ELSIF INSERTING THEN
temp_dml_type_code := 'I';
ELSIF DELETING THEN
temp_dml_type_code := 'D';
END IF;
INSERT INTO TZACC_ACCT (
ACCOUNT_ID
, ROW_START_DATE
, ROW_UPDATE_SEQUENCE_NUM
, DML_TYPE_CODE
, ACCOUNT_NAME
, ADDRESSEE
, ADDRESS_LINE_1
, ADDRESS_LINE_2
, CITY
, STATE_CODE
, POSTAL_CODE
, COUNTRY
, TAX_RATE
, DEFAULT_PURCHASE_ORDER_NUM
, PAYING_ACCOUNT_ID
, EXTERNAL_ACCOUNT_ID
, CEI_SERVICING_DIVISION_NUM
, DEFAULT_PROMPT_1_VALUE
, DEFAULT_PROMPT_2_VALUE
, DEFAULT_PROMPT_3_VALUE
, DEFAULT_PROMPT_4_VALUE
, CEI_CONTRACTING_DIVISION_NUM
, ACCOUNT_START_DATE
, ACCOUNT_DEACTIVATED_FLAG
, USER_PROFILE_EXPIRY_CODE
, ACCOUNT_DESCRIPTION
, ACCOUNT_TYPE_CODE
, ACCOUNT_STATUS_CODE
, EXTERNAL_CUST_ID
, ROW_UPDATE_USER_ID
, ROW_OLTP_UPDATE_DATE
) VALUES (
:new.ACCT_ACCOUNT_ID
, :new.SYSDATE
, :new.S_DWH_CC_SEQ.NEXTVAL
, temp_dml_type_code
, :new.ACCT_NAME
, :new.ACCT_ATTENTION
, :new.ACCT_ADDRESS
, :new.ACCT_ADDRESS2
, :new.ACCT_CITY
, :new.ACCT_REGION
, :new.ACCT_POSTALCODE
, :new.ACCT_COUNTRY
, :new.ACCT_TAXRATE
, :new.ACCT_DEFAULTPONUMBER
, :new.ACCT_BILL_TO_ACCT_ID
, :new.ACCT_EXTERNALACCOUNT
, :new.ACCT_DIVISION_ID
, :new.ACCT_DFLT_PROMPT_1_VAL
, :new.ACCT_DFLT_PROMPT_2_VAL
, :new.ACCT_DFLT_PROMPT_3_VAL
, :new.ACCT_DFLT_PROMPT_4_VAL
, :new.ACCT_OWNING_ID
, :new.ACCT_INSTALL_DT
, :new.ACCT_DELETED_FLAG
, :new.ACCT_EXP_USER_PROF
, :new.ACCT_DESC
, :new.ACCT_TYPE_CD
, :new.ACCT_STS_CD
, :new.ACCT_FKA_CUST_NO
, :new.ACCT_UPDT_UID
, :new.ACCT_UPDT_DT
);
END;
 
Hi,
after getting the compilation error ( in SqlPLus)
type 'show error' and post the message you get, please..

[profile]
 
Shouldnt

[tt]:new.S_DWH_CC_SEQ.NEXTVAL[/tt]

be just

[tt]S_DWH_CC_SEQ.NEXTVAL[/tt]?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top