ORACLE FORM BUILDER 2000 数据列表显示

    技术2022-05-20  50

    ORACLE FORM BUILDER 2000 数据列表显示。

    按钮事件:WHEN-BUTTON-PROCESSED 。

    详细代码如下:

    -- begin --

    DECLARE    V_level                   VARCHAR2 (10);    V_component_item          VARCHAR2 (50);    V_component_description   VARCHAR2 (100);    V_Average_cost            VARCHAR2 (20);    V_QOT_cost                VARCHAR2 (20);    CURSOR C_JP_POST    IS         SELECT   sbe.plan_level,                  msi1.segment1 component_item,                  msi1.description component_description,                  ROUND (NVL (cic.item_cost, '0'), 5) Average_cost,                  ROUND (NVL (cic1.item_cost, '0'), 5) QOT_cost           FROM   slt.slt_bom_explosions sbe,                  inv.mtl_system_items_b msi,                  inv.mtl_system_items_b msi1,                  bom.bom_bill_of_materials bom,                  bom.CST_ITEM_COSTS cic,                  bom.CST_ITEM_COSTS cic1          WHERE       sbe.top_item_id = msi.inventory_item_id                  AND sbe.organization_id = msi.organization_id                  AND sbe.component_item_id = msi1.inventory_item_id                  AND sbe.organization_id = msi1.organization_id                  AND bom.bill_sequence_id = sbe.top_bill_sequence_id                  AND bom.organization_id = sbe.organization_id                  AND bom.assembly_item_id = sbe.top_item_id                  AND sbe.component_item_id = cic.inventory_item_id(+)                  AND sbe.organization_id = cic.organization_id(+)                  AND sbe.component_item_id = cic1.inventory_item_id(+)                  AND sbe.organization_id = cic1.organization_id(+)                  AND bom.alternate_bom_designator IS NULL                  AND sbe.plan_level <> '0'                  AND cic.cost_type_id(+) = '2'                  AND cic1.cost_type_id(+) = '1361'                  AND msi.INVENTORY_ITEM_ID(+) = :SGD_QUOTE_HEADERS_ALL.ITEM_ID                  AND msi.ORGANIZATION_ID(+) =                        :SGD_QUOTE_HEADERS_ALL.ORGANIZATION_ID       ORDER BY   sbe.plan_level, msi1.segment1;    v_count                   number := 1; BEGIN    GO_BLOCK ('SGD_QUOTE_LINES_ALL');    FIRST_RECORD;    FOR ins_post IN C_JP_POST    LOOP       :SGD_QUOTE_LINES_ALL.PLAN_LEVEL := ins_post.plan_level;       :SGD_QUOTE_LINES_ALL.component_item := ins_post.component_item;       :SGD_QUOTE_LINES_ALL.component_description :=ins_post.component_description;       :SGD_QUOTE_LINES_ALL.AVG_COST := ins_post.Average_cost;       :SGD_QUOTE_LINES_ALL.QOT_cost := ins_post.QOT_cost;       NEXT_RECORD;    END LOOP; END;

    -- end --

    详细结束。

    效果图如附件所示。


    最新回复(0)