如何将记录从 oracle 移动到 Cobol 数组?当我移动一个字段时,一切都按预期工作。当我尝试在 Oracle VARRAY 中移动记录时,我无法让它工作。PRO*COBOL 预编译器给出以下错误消息:
Error at line 137, column 12 in file ESF3.ordbso07.PCO
EXEC SQL EXECUTE
...........1
PCB-S-00576, PLS-382: expression is of wrong type
Error at line 137, column 12 in file ESF3.ordbso07.PCO
EXEC SQL EXECUTE
...........1
PCB-S-00576, PLS-0: Statement ignored
甲骨文类型:
TYPE QDELSSRD_arr IS VARRAY(30) OF QDELSSRD_typ;
TYPE SODLSSRD_typ IS RECORD ( -- DBSO07 SOK
QDELSSRD QDELSSRD_arr -- 30 x QDELSSRD_typ
OC is SODLSSRD_typ;
TYPE QDELSSRD_typ IS RECORD (
ENAMN arbetssokande.efternamn%type, -- VARCHAR2(30 CHAR)
FNAMN arbetssokande.fornamn%type, -- VARCHAR2(20 CHAR)
);
COBOL ESQL 匿名 PL/SQL 块的片段:
FOR LV IN 1..:RC-ZHITS
LOOP
:QDELSSRD(LV) := OC.QDELSSRD(LV);
END LOOP;
COBOL 变量声明:
15 QSODLSSRD.
18 QDELSSRD OCCURS 30.
21 ENAMN PIC X(030).
21 FNAMN PIC X(020).