Good day!
i having a problem in inserting new record in yii with oracle as my DB…
CDbCommand failed to prepare the SQL statement: SQLSTATE[HY000]: General error: 1741 OCIStmtPrepare: ORA-01741: illegal zero-length identifier
(ext\pdo_oci\oci_driver.c:279)
the primary key of my table is based on trigger.
CREATE TABLE "ADMIN"."BK_R_BOOK_103"
( "BOOK_UID" NUMBER(18,0) primary key,
"DESCRIPTION" VARCHAR2(100 BYTE),
"PURPOSE" VARCHAR2(200 BYTE)
);
CREATE OR REPLACE TRIGGER "ADMIN"."BK_R_BOOK_103_TRIG"
before insert on "ADMIN"."BK_R_BOOK_103"
for each row
begin
if inserting then
if :NEW."BOOK_UID" is null then
select BK_R_BOOK_103_SEQ.nextval into :NEW."BOOK_UID" from dual;
end if;
end if;
end;
hope you can help me with this…
god bless
thanks.