5

在Oracle PL/SQL中创建数据包,遇到报错:PLS-00103:出现符号“CREATE”,请问如何解决?

本人小白,我在创建基于存储过程的数据块时,第一次按照网上的教程,依葫芦画样创建成功后,运行也成功,但是手贱没有保存,也因为脑残有点飘,第二次自己创建时出现问题,后续把第一次成功做的样例拿出来再对照编写时,不断报错,最后重新把第一次做的样例拿出来已经无法运行,所以来此请教各位大佬。

先把我参考的网址挂出来:https://blog.csdn.net/weixin_33915554/article/details/85448269

接下来,我说一下问题:
我在Oracle的PL/SQL Developer中创建了一个Package: hek_ar_reciept_pg

包中代码贴出来如下:

create or replace package hek_ar_reciept_pg is
       type line_record_type is record(
        LINE_ID                          NUMBER,
        HEADER_ID                        NUMBER,
        CUSTOMER_TRX_ID                  NUMBER,
        APPLY_ACCOUNT                    NUMBER,
        APPLY_DATE                       DATE,
        GL_DATE                          DATE,
        DISCOUNT                         NUMBER,
        REVERSAL_GL_DATE                 DATE,
        AMOUNT_APPLIED_FROM              NUMBER,
        MATCH_FLAG                       VARCHAR2(30),
        APPLY_FLAG                       VARCHAR2(10),
        TRX_NUMBER                       VARCHAR2(30),
        INSTALLMENT                      NUMBER,
        AMOUNT_DUE_REMAINING             NUMBER,
        INVOICE_CURRENCY_CODE            VARCHAR2(15),
        CUSTOMER_NUMBER                  VARCHAR2(30),
        CUSTOMER_ID                      NUMBER,
        CUSTOMER_NAME                    VARCHAR2(50),
        TRX_CLASS_NAME                   VARCHAR2(4000),
        TRX_CLASS_CODE                   VARCHAR2(20),
        TRX_TYPE_NAME                    VARCHAR2(20),
        PURCHASE_ORDER                   VARCHAR2(50),
        CT_REFERENCE                     VARCHAR2(30),
        LOCATION_NAME                    VARCHAR2(40),
        BILL_TO_SITE_USE_ID              NUMBER,
        STATUS                           VARCHAR2(30),
        CASH_RECEIPT_ID                  NUMBER,
        PS_CUSTOMER_TRX_ID               NUMBER,
        TRX_BATCH_SOURCE_NAME            VARCHAR2(50),
        DUE_DATE                         DATE,
        TERM_ID                          NUMBER,
        CUST_TRX_TYPE_ID                 NUMBER,
        PROGRAM_APPLICATION_ID           NUMBER,
        PROGRAM_ID                       NUMBER,
        REQUEST_ID                       NUMBER,
        AMOUNT_DUE_ORIGINAL              NUMBER,
        AMOUNT_IN_DISPUTE                NUMBER,
        AMOUNT_LINE_ITEMS_ORIGINAL       NUMBER,
        ACCTD_AMOUNT_DUE_REMAINING       NUMBER,
        TRX_DATE                         DATE,
        APPLIED_PAYMENT_SCHEDULE_ID      NUMBER,
        CREATED_BY                       NUMBER,
        CREATION_DATE                    DATE,
        LAST_UPDATED_BY                  NUMBER,
        LAST_UPDATE_DATE                 DATE,
        LAST_UPDATE_LOGIN                NUMBER,
        ORG_ID                           NUMBER,
        ATTRIBUTE_CATEGORY               VARCHAR2(30),
        ATTRIBUTE1                       VARCHAR2(50),
        ATTRIBUTE2                       VARCHAR2(50),
        ATTRIBUTE3                       VARCHAR2(50),
        ATTRIBUTE4                       VARCHAR2(50),
        ATTRIBUTE5                       VARCHAR2(50),
        ATTRIBUTE6                       VARCHAR2(50),
        ATTRIBUTE7                       VARCHAR2(50),
        ATTRIBUTE8                       VARCHAR2(50),
        ATTRIBUTE9                       VARCHAR2(50),
        ATTRIBUTE10                      VARCHAR2(50),
        ATTRIBUTE11                      VARCHAR2(150),
        ATTRIBUTE12                      VARCHAR2(150),
        ATTRIBUTE13                      VARCHAR2(150),
        ATTRIBUTE14                      VARCHAR2(150),
        ATTRIBUTE15                      VARCHAR2(150)
       );

type lines_record_type is record(
        LINE_ID                          NUMBER,
        HEADER_ID                        NUMBER,
        CUSTOMER_TRX_ID                  NUMBER,
        APPLY_ACCOUNT                    NUMBER,
        APPLY_DATE                      DATE,
        GL_DATE                          DATE,
        DISCOUNT                        NUMBER,
        REVERSAL_GL_DATE DATE,
        AMOUNT_APPLIED_FROM NUMBER,
        MATCH_FLAG VARCHAR2(30),
        APPLY_FLAG VARCHAR2(10),
        CREATED_BY NUMBER,
        CREATION_DATE DATE,
        LAST_UPDATED_BY NUMBER,
        LAST_UPDATE_DATE DATE,
        LAST_UPDATE_LOGIN NUMBER,
        ORG_ID NUMBER,
        ATTRIBUTE_CATEGORY VARCHAR2(30),
        ATTRIBUTE1 VARCHAR2(50),
        ATTRIBUTE2 VARCHAR2(50),
        ATTRIBUTE3 VARCHAR2(50),
        ATTRIBUTE4 VARCHAR2(50),
        ATTRIBUTE5 VARCHAR2(50),
        ATTRIBUTE6 VARCHAR2(50),
        ATTRIBUTE7 VARCHAR2(50),
        ATTRIBUTE8 VARCHAR2(50),
        ATTRIBUTE9 VARCHAR2(50),
        ATTRIBUTE10 VARCHAR2(50),
        ATTRIBUTE11 VARCHAR2(150),
        ATTRIBUTE12 VARCHAR2(150),
        ATTRIBUTE13 VARCHAR2(150),
        ATTRIBUTE14 VARCHAR2(150),
        ATTRIBUTE15 VARCHAR2(150)
            );


      type line_ref_cursor is ref cursor return line_record_type;
      type line_table_type is table of lines_record_type index by binary_integer;

      procedure line_query(dmlset in out line_ref_cursor);
      procedure line_lock(dmlset in out line_table_type);
      procedure line_insert(dmlset in out line_table_type);
      procedure line_update(dmlset in out line_table_type);
      procedure line_delete(dmlset in out line_table_type);
end;


create or replace package body hek_ar_reciept_pg is


      procedure line_query(dmlset in out line_ref_cursor) is
      begin
          open dmlset for
          select line_id,
                 header_id,
                 customer_trx_id,
                 apply_account,
                 apply_date,
                 gl_date,
                 discount,
                 reversal_gl_date,
                 amount_applied_from,
                 match_flag,
                 apply_flag,
                 trx_number,
                 installment,
                 amount_due_remaining,
                 invoice_currency_code,
                 customer_number,
                 customer_id,
                 customer_name,
                 trx_class_name,
                 trx_class_code,
                 trx_type_name,
                 purchase_order,
                 ct_reference,
                 location_name,
                 bill_to_site_use_id,
                 status,
                 cash_receipt_id,
                 ps_customer_trx_id,
                 trx_batch_source_name,
                 due_date,
                 term_id,
                 cust_trx_type_id,
                 program_application_id,
                 program_id,
                 request_id,
                 amount_due_original,
                 amount_in_dispute,
                 amount_line_items_original,
                 acctd_amount_due_remaining,
                 trx_date,
                 applied_payment_schedule_id,
                 created_by,
                 creation_date,
                 last_updated_by,
                 last_update_date,
                 last_update_login,
                 org_id,
                 attribute_category,
                 attribute1,
                 attribute2,
                 attribute3,
                 attribute4,
                 attribute5,
                 attribute6,
                 attribute7,
                 attribute8,
                 attribute9,
                 attribute10,
                 attribute11,
                 attribute12,
                 attribute13,
                 attribute14,
                 attribute15
            from hek_ar_reciept_lines_v;
      end;

      procedure line_lock(dmlset in out line_table_type) is
           l_line_id number;
      begin
           select line_id
             into l_line_id
             from hek_ar_reciept_lines_all
            where line_id = dmlset(1).line_id
              for update;
      end;

      procedure line_insert(dmlset in out line_table_type) is
      begin
           insert into hek_ar_reciept_lines_all(LINE_ID,
                                                HEADER_ID,
                                                CUSTOMER_TRX_ID,
                                                APPLY_ACCOUNT,
                                                APPLY_DATE,
                                                GL_DATE,
                                                DISCOUNT,
                                                REVERSAL_GL_DATE,
                                                AMOUNT_APPLIED_FROM,
                                                MATCH_FLAG,
                                                APPLY_FLAG,
                                                CREATED_BY,
                                                CREATION_DATE,
                                                LAST_UPDATED_BY,
                                                LAST_UPDATE_DATE,
                                                LAST_UPDATE_LOGIN,
                                                ORG_ID,
                                                ATTRIBUTE_CATEGORY,
                                                ATTRIBUTE1,
                                                ATTRIBUTE2,
                                                ATTRIBUTE3,
                                                ATTRIBUTE4,
                                                ATTRIBUTE5,
                                                ATTRIBUTE6,
                                                ATTRIBUTE7,
                                                ATTRIBUTE8,
                                                ATTRIBUTE9,
                                                ATTRIBUTE10,
                                                ATTRIBUTE11,
                                                ATTRIBUTE12,
                                                ATTRIBUTE13,
                                                ATTRIBUTE14,
                                                ATTRIBUTE15)
                                         values(dmlset(1).LINE_ID,
                                                dmlset(1).HEADER_ID,
                                                dmlset(1).CUSTOMER_TRX_ID,
                                                dmlset(1).APPLY_ACCOUNT,
                                                dmlset(1).APPLY_DATE,
                                                dmlset(1).GL_DATE,
                                                dmlset(1).DISCOUNT,
                                                dmlset(1).REVERSAL_GL_DATE,
                                                dmlset(1).AMOUNT_APPLIED_FROM,
                                                dmlset(1).MATCH_FLAG,
                                                dmlset(1).APPLY_FLAG,
                                                dmlset(1).CREATED_BY,
                                                dmlset(1).CREATION_DATE,
                                                dmlset(1).LAST_UPDATED_BY,
                                                dmlset(1).LAST_UPDATE_DATE,
                                                dmlset(1).LAST_UPDATE_LOGIN,
                                                dmlset(1).ORG_ID,
                                                dmlset(1).ATTRIBUTE_CATEGORY,
                                                dmlset(1).ATTRIBUTE1,
                                                dmlset(1).ATTRIBUTE2,
                                                dmlset(1).ATTRIBUTE3,
                                                dmlset(1).ATTRIBUTE4,
                                                dmlset(1).ATTRIBUTE5,
                                                dmlset(1).ATTRIBUTE6,
                                                dmlset(1).ATTRIBUTE7,
                                                dmlset(1).ATTRIBUTE8,
                                                dmlset(1).ATTRIBUTE9,
                                                dmlset(1).ATTRIBUTE10,
                                                dmlset(1).ATTRIBUTE11,
                                                dmlset(1).ATTRIBUTE12,
                                                dmlset(1).ATTRIBUTE13,
                                                dmlset(1).ATTRIBUTE14,
                                                dmlset(1).ATTRIBUTE15);
      end;

      procedure line_update(dmlset in out line_table_type) is
      begin
          update hek_ar_reciept_lines_all
             set HEADER_ID = dmlset(1).HEADER_ID,--LINE_ID = dmlset(1).LINE_ID,
                 CUSTOMER_TRX_ID = dmlset(1).CUSTOMER_TRX_ID,
                 APPLY_ACCOUNT = dmlset(1).APPLY_ACCOUNT,
                 APPLY_DATE = dmlset(1).APPLY_DATE,
                 GL_DATE = dmlset(1).GL_DATE,
                 DISCOUNT = dmlset(1).DISCOUNT,
                 REVERSAL_GL_DATE = dmlset(1).REVERSAL_GL_DATE,
                 AMOUNT_APPLIED_FROM = dmlset(1).AMOUNT_APPLIED_FROM,
                 MATCH_FLAG = dmlset(1).MATCH_FLAG,
                 APPLY_FLAG = dmlset(1).APPLY_FLAG,
                 CREATED_BY = dmlset(1).CREATED_BY,
                 CREATION_DATE = dmlset(1).CREATION_DATE,
                 LAST_UPDATED_BY = dmlset(1).LAST_UPDATED_BY,
                 LAST_UPDATE_DATE = dmlset(1).LAST_UPDATE_DATE,
                 LAST_UPDATE_LOGIN = dmlset(1).LAST_UPDATE_LOGIN,
                 ORG_ID = dmlset(1).ORG_ID,
                 ATTRIBUTE_CATEGORY = dmlset(1).ATTRIBUTE_CATEGORY,
                 ATTRIBUTE1 = dmlset(1).ATTRIBUTE1,
                 ATTRIBUTE2 = dmlset(1).ATTRIBUTE2,
                 ATTRIBUTE3 = dmlset(1).ATTRIBUTE3,
                 ATTRIBUTE4 = dmlset(1).ATTRIBUTE4,
                 ATTRIBUTE5 = dmlset(1).ATTRIBUTE5,
                 ATTRIBUTE6 = dmlset(1).ATTRIBUTE6,
                 ATTRIBUTE7 = dmlset(1).ATTRIBUTE7,
                 ATTRIBUTE8 = dmlset(1).ATTRIBUTE8,
                 ATTRIBUTE9 = dmlset(1).ATTRIBUTE9,
                 ATTRIBUTE10 = dmlset(1).ATTRIBUTE10,
                 ATTRIBUTE11 = dmlset(1).ATTRIBUTE11,
                 ATTRIBUTE12 = dmlset(1).ATTRIBUTE12,
                 ATTRIBUTE13 = dmlset(1).ATTRIBUTE13,
                 ATTRIBUTE14 = dmlset(1).ATTRIBUTE14,
                 ATTRIBUTE15 = dmlset(1).ATTRIBUTE15
            where line_id = dmlset(1).line_id;
      end;

      procedure line_delete(dmlset in out line_table_type) is
      begin
          delete from hek_ar_reciept_lines_all
                where line_id = dmlset(1).line_id;
      end;
end;

但是执行后,代码第118行出现报错
118:create or replace package body hek_ar_reciept_pg is

错误为:118 PLS-00103:出现符号“CREATE”
图片说明

(这里代码行数118是我现在电脑上的行数,对照截图可能有一两行空白行的出入)

针对这个错误,我看了好多帖子,但是始终有错,后来,我觉得饭一口一口吃,从第118行开始全部删掉,只留下上面line_record_type记录部分,后成功运行,无报错,
图片说明

但是,这个时候,我在Oracle Forms builder中创建数据库向导的时候,发现在输入过程的时候,我输入:hek_ar_reciept_pg.line_query或hek_ar_reciept_pg.line_record,刷新的时候,发现报错 FRM-10760:描述存储过程时遇到错误,
图片说明
最后重新把第一次做的样例拿出来已经无法运行,所以来此请教各位大佬。

先把我参考的网址挂出来:https://blog.csdn.net/weixin_33915554/article/details/85448269

接下来,我说一下问题:
我在Oracle的PL/SQL Developer中创建了一个Package: hek_ar_reciept_pg

包中代码贴出来如下:

create or replace package hek_ar_reciept_pg is
       type line_record_type is record(
        LINE_ID                          NUMBER,
        HEADER_ID                        NUMBER,
        CUSTOMER_TRX_ID                  NUMBER,
        APPLY_ACCOUNT                    NUMBER,
        APPLY_DATE                       DATE,
        GL_DATE                          DATE,
        DISCOUNT                         NUMBER,
        REVERSAL_GL_DATE                 DATE,
        AMOUNT_APPLIED_FROM              NUMBER,
        MATCH_FLAG                       VARCHAR2(30),
        APPLY_FLAG                       VARCHAR2(10),
        TRX_NUMBER                       VARCHAR2(30),
        INSTALLMENT                      NUMBER,
        AMOUNT_DUE_REMAINING             NUMBER,
        INVOICE_CURRENCY_CODE            VARCHAR2(15),
        CUSTOMER_NUMBER                  VARCHAR2(30),
        CUSTOMER_ID                      NUMBER,
        CUSTOMER_NAME                    VARCHAR2(50),
        TRX_CLASS_NAME                   VARCHAR2(4000),
        TRX_CLASS_CODE                   VARCHAR2(20),
        TRX_TYPE_NAME                    VARCHAR2(20),
        PURCHASE_ORDER                   VARCHAR2(50),
        CT_REFERENCE                     VARCHAR2(30),
        LOCATION_NAME                    VARCHAR2(40),
        BILL_TO_SITE_USE_ID              NUMBER,
        STATUS                           VARCHAR2(30),
        CASH_RECEIPT_ID                  NUMBER,
        PS_CUSTOMER_TRX_ID               NUMBER,
        TRX_BATCH_SOURCE_NAME            VARCHAR2(50),
        DUE_DATE                         DATE,
        TERM_ID                          NUMBER,
        CUST_TRX_TYPE_ID                 NUMBER,
        PROGRAM_APPLICATION_ID           NUMBER,
        PROGRAM_ID                       NUMBER,
        REQUEST_ID                       NUMBER,
        AMOUNT_DUE_ORIGINAL              NUMBER,
        AMOUNT_IN_DISPUTE                NUMBER,
        AMOUNT_LINE_ITEMS_ORIGINAL       NUMBER,
        ACCTD_AMOUNT_DUE_REMAINING       NUMBER,
        TRX_DATE                         DATE,
        APPLIED_PAYMENT_SCHEDULE_ID      NUMBER,
        CREATED_BY                       NUMBER,
        CREATION_DATE                    DATE,
        LAST_UPDATED_BY                  NUMBER,
        LAST_UPDATE_DATE                 DATE,
        LAST_UPDATE_LOGIN                NUMBER,
        ORG_ID                           NUMBER,
        ATTRIBUTE_CATEGORY               VARCHAR2(30),
        ATTRIBUTE1                       VARCHAR2(50),
        ATTRIBUTE2                       VARCHAR2(50),
        ATTRIBUTE3                       VARCHAR2(50),
        ATTRIBUTE4                       VARCHAR2(50),
        ATTRIBUTE5                       VARCHAR2(50),
        ATTRIBUTE6                       VARCHAR2(50),
        ATTRIBUTE7                       VARCHAR2(50),
        ATTRIBUTE8                       VARCHAR2(50),
        ATTRIBUTE9                       VARCHAR2(50),
        ATTRIBUTE10                      VARCHAR2(50),
        ATTRIBUTE11                      VARCHAR2(150),
        ATTRIBUTE12                      VARCHAR2(150),
        ATTRIBUTE13                      VARCHAR2(150),
        ATTRIBUTE14                      VARCHAR2(150),
        ATTRIBUTE15                      VARCHAR2(150)
       );

type lines_record_type is record(
        LINE_ID                          NUMBER,
        HEADER_ID                        NUMBER,
        CUSTOMER_TRX_ID                  NUMBER,
        APPLY_ACCOUNT                    NUMBER,
        APPLY_DATE                      DATE,
        GL_DATE                          DATE,
        DISCOUNT                        NUMBER,
        REVERSAL_GL_DATE DATE,
        AMOUNT_APPLIED_FROM NUMBER,
        MATCH_FLAG VARCHAR2(30),
        APPLY_FLAG VARCHAR2(10),
        CREATED_BY NUMBER,
        CREATION_DATE DATE,
        LAST_UPDATED_BY NUMBER,
        LAST_UPDATE_DATE DATE,
        LAST_UPDATE_LOGIN NUMBER,
        ORG_ID NUMBER,
        ATTRIBUTE_CATEGORY VARCHAR2(30),
        ATTRIBUTE1 VARCHAR2(50),
        ATTRIBUTE2 VARCHAR2(50),
        ATTRIBUTE3 VARCHAR2(50),
        ATTRIBUTE4 VARCHAR2(50),
        ATTRIBUTE5 VARCHAR2(50),
        ATTRIBUTE6 VARCHAR2(50),
        ATTRIBUTE7 VARCHAR2(50),
        ATTRIBUTE8 VARCHAR2(50),
        ATTRIBUTE9 VARCHAR2(50),
        ATTRIBUTE10 VARCHAR2(50),
        ATTRIBUTE11 VARCHAR2(150),
        ATTRIBUTE12 VARCHAR2(150),
        ATTRIBUTE13 VARCHAR2(150),
        ATTRIBUTE14 VARCHAR2(150),
        ATTRIBUTE15 VARCHAR2(150)
            );


      type line_ref_cursor is ref cursor return line_record_type;
      type line_table_type is table of lines_record_type index by binary_integer;

      procedure line_query(dmlset in out line_ref_cursor);
      procedure line_lock(dmlset in out line_table_type);
      procedure line_insert(dmlset in out line_table_type);
      procedure line_update(dmlset in out line_table_type);
      procedure line_delete(dmlset in out line_table_type);
end;


create or replace package body hek_ar_reciept_pg is


      procedure line_query(dmlset in out line_ref_cursor) is
      begin
          open dmlset for
          select line_id,
                 header_id,
                 customer_trx_id,
                 apply_account,
                 apply_date,
                 gl_date,
                 discount,
                 reversal_gl_date,
                 amount_applied_from,
                 match_flag,
                 apply_flag,
                 trx_number,
                 installment,
                 amount_due_remaining,
                 invoice_currency_code,
                 customer_number,
                 customer_id,
                 customer_name,
                 trx_class_name,
                 trx_class_code,
                 trx_type_name,
                 purchase_order,
                 ct_reference,
                 location_name,
                 bill_to_site_use_id,
                 status,
                 cash_receipt_id,
                 ps_customer_trx_id,
                 trx_batch_source_name,
                 due_date,
                 term_id,
                 cust_trx_type_id,
                 program_application_id,
                 program_id,
                 request_id,
                 amount_due_original,
                 amount_in_dispute,
                 amount_line_items_original,
                 acctd_amount_due_remaining,
                 trx_date,
                 applied_payment_schedule_id,
                 created_by,
                 creation_date,
                 last_updated_by,
                 last_update_date,
                 last_update_login,
                 org_id,
                 attribute_category,
                 attribute1,
                 attribute2,
                 attribute3,
                 attribute4,
                 attribute5,
                 attribute6,
                 attribute7,
                 attribute8,
                 attribute9,
                 attribute10,
                 attribute11,
                 attribute12,
                 attribute13,
                 attribute14,
                 attribute15
            from hek_ar_reciept_lines_v;
      end;

      procedure line_lock(dmlset in out line_table_type) is
           l_line_id number;
      begin
           select line_id
             into l_line_id
             from hek_ar_reciept_lines_all
            where line_id = dmlset(1).line_id
              for update;
      end;

      procedure line_insert(dmlset in out line_table_type) is
      begin
           insert into hek_ar_reciept_lines_all(LINE_ID,
                                                HEADER_ID,
                                                CUSTOMER_TRX_ID,
                                                APPLY_ACCOUNT,
                                                APPLY_DATE,
                                                GL_DATE,
                                                DISCOUNT,
                                                REVERSAL_GL_DATE,
                                                AMOUNT_APPLIED_FROM,
                                                MATCH_FLAG,
                                                APPLY_FLAG,
                                                CREATED_BY,
                                                CREATION_DATE,
                                                LAST_UPDATED_BY,
                                                LAST_UPDATE_DATE,
                                                LAST_UPDATE_LOGIN,
                                                ORG_ID,
                                                ATTRIBUTE_CATEGORY,
                                                ATTRIBUTE1,
                                                ATTRIBUTE2,
                                                ATTRIBUTE3,
                                                ATTRIBUTE4,
                                                ATTRIBUTE5,
                                                ATTRIBUTE6,
                                                ATTRIBUTE7,
                                                ATTRIBUTE8,
                                                ATTRIBUTE9,
                                                ATTRIBUTE10,
                                                ATTRIBUTE11,
                                                ATTRIBUTE12,
                                                ATTRIBUTE13,
                                                ATTRIBUTE14,
                                                ATTRIBUTE15)
                                         values(dmlset(1).LINE_ID,
                                                dmlset(1).HEADER_ID,
                                                dmlset(1).CUSTOMER_TRX_ID,
                                                dmlset(1).APPLY_ACCOUNT,
                                                dmlset(1).APPLY_DATE,
                                                dmlset(1).GL_DATE,
                                                dmlset(1).DISCOUNT,
                                                dmlset(1).REVERSAL_GL_DATE,
                                                dmlset(1).AMOUNT_APPLIED_FROM,
                                                dmlset(1).MATCH_FLAG,
                                                dmlset(1).APPLY_FLAG,
                                                dmlset(1).CREATED_BY,
                                                dmlset(1).CREATION_DATE,
                                                dmlset(1).LAST_UPDATED_BY,
                                                dmlset(1).LAST_UPDATE_DATE,
                                                dmlset(1).LAST_UPDATE_LOGIN,
                                                dmlset(1).ORG_ID,
                                                dmlset(1).ATTRIBUTE_CATEGORY,
                                                dmlset(1).ATTRIBUTE1,
                                                dmlset(1).ATTRIBUTE2,
                                                dmlset(1).ATTRIBUTE3,
                                                dmlset(1).ATTRIBUTE4,
                                                dmlset(1).ATTRIBUTE5,
                                                dmlset(1).ATTRIBUTE6,
                                                dmlset(1).ATTRIBUTE7,
                                                dmlset(1).ATTRIBUTE8,
                                                dmlset(1).ATTRIBUTE9,
                                                dmlset(1).ATTRIBUTE10,
                                                dmlset(1).ATTRIBUTE11,
                                                dmlset(1).ATTRIBUTE12,
                                                dmlset(1).ATTRIBUTE13,
                                                dmlset(1).ATTRIBUTE14,
                                                dmlset(1).ATTRIBUTE15);
      end;

      procedure line_update(dmlset in out line_table_type) is
      begin
          update hek_ar_reciept_lines_all
             set HEADER_ID = dmlset(1).HEADER_ID,--LINE_ID = dmlset(1).LINE_ID,
                 CUSTOMER_TRX_ID = dmlset(1).CUSTOMER_TRX_ID,
                 APPLY_ACCOUNT = dmlset(1).APPLY_ACCOUNT,
                 APPLY_DATE = dmlset(1).APPLY_DATE,
                 GL_DATE = dmlset(1).GL_DATE,
                 DISCOUNT = dmlset(1).DISCOUNT,
                 REVERSAL_GL_DATE = dmlset(1).REVERSAL_GL_DATE,
                 AMOUNT_APPLIED_FROM = dmlset(1).AMOUNT_APPLIED_FROM,
                 MATCH_FLAG = dmlset(1).MATCH_FLAG,
                 APPLY_FLAG = dmlset(1).APPLY_FLAG,
                 CREATED_BY = dmlset(1).CREATED_BY,
                 CREATION_DATE = dmlset(1).CREATION_DATE,
                 LAST_UPDATED_BY = dmlset(1).LAST_UPDATED_BY,
                 LAST_UPDATE_DATE = dmlset(1).LAST_UPDATE_DATE,
                 LAST_UPDATE_LOGIN = dmlset(1).LAST_UPDATE_LOGIN,
                 ORG_ID = dmlset(1).ORG_ID,
                 ATTRIBUTE_CATEGORY = dmlset(1).ATTRIBUTE_CATEGORY,
                 ATTRIBUTE1 = dmlset(1).ATTRIBUTE1,
                 ATTRIBUTE2 = dmlset(1).ATTRIBUTE2,
                 ATTRIBUTE3 = dmlset(1).ATTRIBUTE3,
                 ATTRIBUTE4 = dmlset(1).ATTRIBUTE4,
                 ATTRIBUTE5 = dmlset(1).ATTRIBUTE5,
                 ATTRIBUTE6 = dmlset(1).ATTRIBUTE6,
                 ATTRIBUTE7 = dmlset(1).ATTRIBUTE7,
                 ATTRIBUTE8 = dmlset(1).ATTRIBUTE8,
                 ATTRIBUTE9 = dmlset(1).ATTRIBUTE9,
                 ATTRIBUTE10 = dmlset(1).ATTRIBUTE10,
                 ATTRIBUTE11 = dmlset(1).ATTRIBUTE11,
                 ATTRIBUTE12 = dmlset(1).ATTRIBUTE12,
                 ATTRIBUTE13 = dmlset(1).ATTRIBUTE13,
                 ATTRIBUTE14 = dmlset(1).ATTRIBUTE14,
                 ATTRIBUTE15 = dmlset(1).ATTRIBUTE15
            where line_id = dmlset(1).line_id;
      end;

      procedure line_delete(dmlset in out line_table_type) is
      begin
          delete from hek_ar_reciept_lines_all
                where line_id = dmlset(1).line_id;
      end;
end;

但是执行后,代码第118行出现报错
118:create or replace package body hek_ar_reciept_pg is

错误为:118 PLS-00103:出现符号“CREATE”
图片说明

(这里代码行数118是我现在电脑上的行数,对照截图可能有一两行空白行的出入)

针对这个错误,我看了好多帖子,但是始终有错,后来,我觉得饭一口一口吃,从第118行开始全部删掉,只留下上面line_record_type记录部分,后成功运行,无报错,
图片说明

但是,这个时候,我在Oracle Forms builder中创建数据库向导的时候,发现在输入过程的时候,我输入:hek_ar_reciept_pg.line_query或hek_ar_reciept_pg.line_record,刷新的时候,发现报错 FRM-10760:描述存储过程时遇到错误,
图片说明
接下来始终卡在这里,进退不得,一方面无法进行数据块的创建,另一方面在Oracle PL/SQL developer中也没什么好办法继续下去,麻烦各位大佬讲解一下,指导一二,感激不尽!


以上是第一次的问题,后面听取了各位意见后,我通过重建数据库,初步实现了目的,但是实际上,还是有些问题的,比如:我在数据库编写数据包时,遇到如下问题:
图片说明
图片说明
虽然依旧能跑,但是毫无疑问,功能是有问题的
如下:
图片说明
图片说明

请问,在PL/SQL中的数据包中,怎么修改才能解决这个问题?请求指点,谢谢!

查看全部
Aeron_Lee
理衣烦
2020/02/26 11:51
  • oracle
  • 点赞
  • 收藏
  • 回答
    私信
满意答案
查看全部

1个回复