记录未通过PLSQL过程保存在表中

时间:2019-01-02 08:22:14

标签: oracle plsql plsqldeveloper

我正在尝试在DELIVERY_DETAILS中创建一条记录,但是该记录未保存在表中。单独运行查询会保存该记录。 成功编译。

    CREATE OR REPLACE procedure CreateShipmentLinesTest

IS

BEGIN

INSERT INTO WSH_DELIVERY_DETAILS("DELIVERY_DETAIL_ID","SALES_ORDER_NUMBER","SALES_ORDER_LINE_NUMBER","SOURCE_SHIPMENT_NUMBER","SOURCE_SHIPMENT_ID","ORGANIZATION_ID",
"SOURCE_LINE_TYPE","CREATED_BY","SOURCE_LINE_ID","SHIP_FROM_LOCATION_ID","REQUESTED_QUANTITY","REQUESTED_QUANTITY_UOM",
"CREATION_DATE","LAST_UPDATE_DATE","LAST_UPDATED_BY","OBJECT_VERSION_NUMBER") values (007023,'AK_JAN02_2019','1','1.1.1',20001,207,'SALES_ORDER',1006,4602,207,250,'Ea','01-MAR-96 12.00.00.000000000 AM','06-FEB-17 01.10.16.000000000 AM'
,'FUSION',2);
COMMIT;

BEGIN
  CreateShipmentLinesTest;
END;
END;
/

1 个答案:

答案 0 :(得分:3)

compiling仅用于编译存储过程。这不会执行您的存储过程。

为了执行存储过程,您需要使用以下命令运行过程:

exec CreateShipmentLinesTest;

BEGIN
  CreateShipmentLinesTest;
END;