Tuesday, 14 September 2021

Oracle EBS - How to upload bulk Material Transaction Reason

Subject: How to upload bulk Material Transaction Reason in Oracle EBS.

Pre-requisite: We need to store Reason Name and Description fields Values in a temporary table for bulk data.

EBS Navigation: Iventory > Setup > Transactions > Reasons



--Base Table:-- MTL_TRANSACTION_REASONS

--PLSQL Scripts--

DECLARE

    v_rowid   NUMBER;

    v_rowid1  VARCHAR2(1000);

BEGIN

    fnd_global.apps_initialize(user_id => 25665, resp_id => 52895, resp_appl_id => 0);


    fnd_msg_pub.initialize;

    FOR i IN (

        SELECT

            *

        FROM

            temp_lookup_tbl

        WHERE

            lookup_type = 'MTL_TRANSACTION_REASON' 

--                and MEANING in ('PS-Metallicplate of switch-127','PS-Metallicplate of switch-159')

--                and rownum=1

    ) LOOP

        INSERT INTO mtl_transaction_reasons (

            reason_id,

            last_update_date,

            last_updated_by,

            creation_date,

            created_by,

            last_update_login,

            reason_name,

            description,

            attribute2,

            reason_type,

            reason_type_display

        ) VALUES (

            mtl_transaction_reasons_s.NEXTVAL,

            sysdate,

            - 1,

            sysdate,

            - 1,

            - 1,

            i.meaning,

            i.description,

            i.org,

            8,

            'QA Update Status'

        );


    END LOOP;


    COMMIT;

END;

No comments:

Post a Comment

Note: only a member of this blog may post a comment.