Batch load script for Order Management with Oracle R12 EBS

Hello,
I am looking for a way to load a million dummy test records into Order Management. For example, I would like to automate a batch process to generate a million new sales orders for Oracle 12.1.1 EBS on Linux platform. If anyone has an idea on how to script this, would appreciate your help.

Two questions:
1. How would I modify the following script to generate a million new orders for OM:
2. How can I register and create a concurrent program with the script?
SET SERVEROUTPUT ON;
DECLARE
v_api_version_number NUMBER := 1;
v_return_status VARCHAR2(2000);
v_msg_count NUMBER;
v_msg_data VARCHAR2(2000);
-- IN Variables --
v_header_rec oe_order_pub.header_rec_type;
v_line_tbl oe_order_pub.line_tbl_type;
v_action_request_tbl oe_order_pub.request_tbl_type;
v_line_adj_tbl oe_order_pub.line_adj_tbl_type;
-- OUT Variables --
v_header_rec_out oe_order_pub.header_rec_type;
v_header_val_rec_out oe_order_pub.header_val_rec_type;
v_header_adj_tbl_out oe_order_pub.header_adj_tbl_type;
v_header_adj_val_tbl_out oe_order_pub.header_adj_val_tbl_type;
v_header_price_att_tbl_out oe_order_pub.header_price_att_tbl_type;
v_header_adj_att_tbl_out oe_order_pub.header_adj_att_tbl_type;
v_header_adj_assoc_tbl_out oe_order_pub.header_adj_assoc_tbl_type;
v_header_scredit_tbl_out oe_order_pub.header_scredit_tbl_type;
v_header_scredit_val_tbl_out oe_order_pub.header_scredit_val_tbl_type;
v_line_tbl_out oe_order_pub.line_tbl_type;
v_line_val_tbl_out oe_order_pub.line_val_tbl_type;
v_line_adj_tbl_out oe_order_pub.line_adj_tbl_type;
v_line_adj_val_tbl_out oe_order_pub.line_adj_val_tbl_type;
v_line_price_att_tbl_out oe_order_pub.line_price_att_tbl_type;
v_line_adj_att_tbl_out oe_order_pub.line_adj_att_tbl_type;
v_line_adj_assoc_tbl_out oe_order_pub.line_adj_assoc_tbl_type;
v_line_scredit_tbl_out oe_order_pub.line_scredit_tbl_type;
v_line_scredit_val_tbl_out oe_order_pub.line_scredit_val_tbl_type;
v_lot_serial_tbl_out oe_order_pub.lot_serial_tbl_type;
v_lot_serial_val_tbl_out oe_order_pub.lot_serial_val_tbl_type;
v_action_request_tbl_out oe_order_pub.request_tbl_type;
BEGIN
DBMS_OUTPUT.PUT_LINE('Starting of script');
-- Setting the Enviroment --
mo_global.init('ONT');
fnd_global.apps_initialize ( user_id => 123
,resp_id => 456
,resp_appl_id => 789);
mo_global.set_policy_context('S',785);
-- Header Record --
v_header_rec := oe_order_pub.g_miss_header_rec;
v_header_rec.operation := oe_globals.g_opr_create;
v_header_rec.order_type_id := 1005;
v_header_rec.sold_to_org_id := 7157;
v_header_rec.ship_to_org_id := 5480;
v_header_rec.invoice_to_org_id := 5181;
v_header_rec.order_source_id := 0;
v_header_rec.booked_flag := 'N';
v_header_rec.price_list_id := 7018;
v_header_rec.pricing_date := SYSDATE;
v_header_rec.flow_status_code := 'ENTERED';
v_header_rec.cust_po_number := '99478222532';
v_header_rec.sold_from_org_id := 83;
v_header_rec.salesrep_id := -3;
v_header_rec.transactional_curr_code:= 'GBP';
v_action_request_tbl (1) := oe_order_pub.g_miss_request_rec;
-- Line Record --
v_line_tbl (1) := oe_order_pub.g_miss_line_rec;
v_line_tbl (1).operation := oe_globals.g_opr_create;
v_line_tbl (1).inventory_item_id := 27893;
v_line_tbl (1).ordered_quantity := 1;
v_line_tbl (1).unit_selling_price := 2000;
v_line_tbl (1).calculate_price_flag := 'Y';
DBMS_OUTPUT.PUT_LINE('Starting of API');
-- Calling the API to create an Order --
OE_ORDER_PUB.PROCESS_ORDER (
p_api_version_number => v_api_version_number
, p_header_rec => v_header_rec
, p_line_tbl => v_line_tbl
, p_action_request_tbl => v_action_request_tbl
, p_line_adj_tbl => v_line_adj_tbl
-- OUT variables
, x_header_rec => v_header_rec_out
, x_header_val_rec => v_header_val_rec_out
, x_header_adj_tbl => v_header_adj_tbl_out
, x_header_adj_val_tbl => v_header_adj_val_tbl_out
, x_header_price_att_tbl => v_header_price_att_tbl_out
, x_header_adj_att_tbl => v_header_adj_att_tbl_out
, x_header_adj_assoc_tbl => v_header_adj_assoc_tbl_out
, x_header_scredit_tbl => v_header_scredit_tbl_out
, x_header_scredit_val_tbl => v_header_scredit_val_tbl_out
, x_line_tbl => v_line_tbl_out
, x_line_val_tbl => v_line_val_tbl_out
, x_line_adj_tbl => v_line_adj_tbl_out
, x_line_adj_val_tbl => v_line_adj_val_tbl_out
, x_line_price_att_tbl => v_line_price_att_tbl_out
, x_line_adj_att_tbl => v_line_adj_att_tbl_out
, x_line_adj_assoc_tbl => v_line_adj_assoc_tbl_out
, x_line_scredit_tbl => v_line_scredit_tbl_out
, x_line_scredit_val_tbl => v_line_scredit_val_tbl_out
, x_lot_serial_tbl => v_lot_serial_tbl_out
, x_lot_serial_val_tbl => v_lot_serial_val_tbl_out
, x_action_request_tbl => v_action_request_tbl_out
, x_return_status => v_return_status
, x_msg_count => v_msg_count
, x_msg_data => v_msg_data
DBMS_OUTPUT.PUT_LINE('Completion of API');
IF v_return_status = fnd_api.g_ret_sts_success THEN
COMMIT;
DBMS_OUTPUT.put_line ('Order Import Success : '||v_header_rec_out.header_id);
ELSE
DBMS_OUTPUT.put_line ('Order Import failed:'||v_msg_data);
ROLLBACK;
FOR i IN 1 .. v_msg_count
LOOP
v_msg_data := oe_msg_pub.get( p_msg_index => i, p_encoded => 'F');
dbms_output.put_line( i|| ') '|| v_msg_data);
END LOOP;
END IF;
END;
/

Similar Messages

  • Any best practice for Key Management with Oracle Obfuscation?

    Hi,
    I was wondering if anyone is aware if there are any best practices regarding key management when using Oracle's DBMS_OBFUSCATION_TOOLKIT? I'm particularly interested in how we can protect the encryption/decryption key that we would use.
    Thanks,
    Jim

    Oracle offers this document, which includes a strategy for what you're after:
    http://download-west.oracle.com/docs/cd/B13789_01/network.101/b10773/apdvncrp.htm#1006234
    -Chuck

  • Oracle R12 EBS installation on CentOS Linux 5

    Per MOS Note 761566.1 , I am installing Oracle 12.1.1 EBS on CentOS 5.5 Linux 64 bit servers. Issue is that I cannot find the packages listed below which are required for 64 Bit Linux installation with Oracle R12 EBS:
    The following packages must be installed from the OEL 5 or RHEL 5 distribution media:
    gcc-4.1.2-14.el5.x86_64
    gcc-c++-4.1.2-14.el5.x86_64
    glibc-2.5-18.i686 (32-bit)
    glibc-2.5-18.x86_64
    glibc-common-2.5-18.x86_64
    glibc-devel-2.5-18.i386 (32-bit)
    glibc-devel-2.5-18.x86_64
    libgcc-4.1.2-14.el5.i386
    libgcc-4.1.2-14.el5.x86_64
    libstdc++-devel-4.1.2-14.el5.i386
    libstdc++-devel-4.1.2-14.el5.x86_64
    libstdc++-4.1.2-14.el5.i386
    libstdc++-4.1.2-14.el5.x86_64
    make-3.81-1.1.x86_64
    gdbm-1.8.0-26.2.1.i386
    gdbm-1.8.0-26.2.1.x86_64
    libXp-1.0.0-8.1.el5.i386
    libXp-1.0.0-8.1.el5.x86_64
    libaio-0.3.106-3.2.i386
    libaio-0.3.106-3.2.x86_64
    libgomp-4.1.2-14.el5.x86_64
    sysstat-7.0.0-3.el5.x86_64
    util-linux-2.13-0.45.el5.x86_64
    compat-libstdc++-296-2.96-138.i386
    compat-libstdc++-33-3.2.3-61.i386
    Additionally, the following RPMs are required for an 11gR1 Database (which is bundled with the 12.1.1 release) on the database tier:
    compat-libstdc++-33-3.2.3-61.x86_64
    elfutils-libelf-devel-0.125-3.el5.x86_64
    elfutils-libelf-devel-static-0.125-3.el5.x86_64
    libaio-devel-0.3.106-3.2.x86_64
    unixODBC-2.2.11-7.1.i386
    unixODBC-devel-2.2.11-7.1.i386
    unixODBC-2.2.11-7.1.x86_64
    unixODBC-devel-2.2.11-7.1.x86_64
    kernel-headers-2.6.18-8.el5.x86_64
    I cannot find these at the http://oss.oracle.com/projects/compat-oracle/files/Enterprise_Linux
    site for CentOS 5.5 and they are not at the CentOS site either.
    Any ideas where to obtain these required Linux packages for CentOS 5.5?
    Thanks!
    Ben

    Ben,
    CentOS is not certified as a database/application tier node.
    You can find the packages from the Media Pack (Download it from e-Delivery website), or just search Google (below is an example):
    Download compat-libstdc++-33-3.2.3-61.x86_64
    http://tinyurl.com/33rj6ea
    Thanks,
    Hussein

  • Order Management with OPM

    Hi Friends
    i'm using order management with Process execution ...when i create a sales order and try to access the Reservation details from Tools menu to reserve the SO against Batch i got an error
    APP-GMI-83900: OPM Manual Allocation is not avaialable
    i'm using : 11.5.10.2
    Regards
    Amr Hussien

    Hi Amr,
    You would have attached the "Allocation class" for that item right. Please check the Parameter for the particular "Allocation Class" where you would have mentioned "TYPE = AUTOMATIC". Upto my knowledge thats the issue in your case.
    Razzy.
    One request to you Amr.
    Can you share Setup and Flow of "Oracle Purchasing and OPM Quality" integration with me. Beacuse i am facing problem from the scratch and i am thinking to setup "Oracle Quality" for the Receiving inspection in Oracle Purchasing. Is it right?
    Please advice me with your experience in this Regard.
    Razzy

  • Creating SQL-Loader script for more than one table at a time

    Hi,
    I am using OMWB 2.0.2.0.0 with Oracle 8.1.7 and Sybase 11.9.
    It looks like I can create SQL-Loader scripts for all the tables
    or for one table at a time. If I want to create SQL-Loader
    scripts for 5-6 tables, I have to either create script for all
    the tables and then delete the unwanted tables or create the
    scripts for one table at a time and then merge them.
    Is there a simple way to create migration scripts for more than
    one but not all tables at a time?
    Thanks,
    Prashant Rane

    No there is no multi-select for creating SQL-Loader scripts.
    You can either create them separately or create them all and
    then discard the one you do not need.

  • Batches not getting  for order components at time of order creation

    Hi Folks,
    My requirement is that when I create a production order and save automatic batch determination should take place for all components. For this I have done all the settings for eg
    1) Assigment of batch search proceduree to order type
    2) Define batch search strategy,procedure , condition , access sequence
    3) Create batch strategy record for order type/ plant/component by COB1
    4) Create sort rule and assign to batch strategy record
    5) Batch classification is there and value of the sort chracteristic is populated in all batches
    6) There is enough available stock in the batch at that storage location
    But batch field is not getting populated .. Even if I press the batch determintion button manually
    on the component overview screen batch selection screen is appearing but no batches are getting determined for selection .I have checked the selection criteria and it is correct and I was expecting batch 'ZSWETA' to b determined as it is satisfying the selection criteria. I am really wondering why this is happening as I have done all the required config settings but batch determination is not happening..
    Can you please help me out of this...
    Regards
    Suchandra

    Hi,
    kindly check the following things-:
    Material master -: Purchasing View tick in check box of Batch Management
                               MRP 2 -:Batch Entry(Select 3-Auto Batch entry on Release)
                              Work Scheduling -: Batch Entry & Batch Management.
    hope it will help you to get the auto Batch Number.
    Regards,
    Mukesh

  • Cannot load script for execution.

    hi 
     iam creating  the  sisi package  with in script task . script task   was  build successful .  but when i was executive the ssis packages vs 2012.
     it get  error :Cannot load script for execution..
     the code is 
       Microsoft SQL Server Integration Services Script Task
       Write scripts using Microsoft Visual C# 2008.
       The ScriptMain is the entry point class of the script.
    using System;
    using System.Data;
    using Microsoft.SqlServer.Dts.Runtime;
    using System.Windows.Forms;
    using System.IO;
    namespace ST_8cdbf584a74b48abb384d8f03cf42f4d.csproj
        public partial class ScriptMain : Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase
            #region VSTA generated code
            enum ScriptResults
                Success = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Success,
                Failure = Microsoft.SqlServer.Dts.Runtime.DTSExecResult.Failure
            #endregion
    The execution engine calls this method when the task executes.
    To access the object model, use the Dts property. Connections, variables, events,
    and logging features are available as members of the Dts property as shown in the following examples.
    To reference a variable, call Dts.Variables["MyCaseSensitiveVariableName"].Value;
    To post a log entry, call Dts.Log("This is my log text", 999, null);
    To fire an event, call Dts.Events.FireInformation(99, "test", "hit the help message", "", 0, true);
    To use the connections collection use something like the following:
    ConnectionManager cm = Dts.Connections.Add("OLEDB");
    cm.ConnectionString = "Data Source=localhost;Initial Catalog=AdventureWorks;Provider=SQLNCLI10;Integrated Security=SSPI;Auto Translate=False;";
    Before returning from this method, set the value of Dts.TaskResult to indicate success or failure.
    To open Help, press F1.
            public void Main()
                byte[] dataByte = null; String errInfo = "";
                try
                    String sDirectory = Dts.Variables["User::Directory"].Value.ToString();
                    String CreatePartitionFileXMLA = sDirectory + "\\partitionssales20010701to20010731.XMLA";
                    String ProcessPartitionFileXMLA = sDirectory + "\\partitionssales20010701to20010731.XMLA";
                    // Create XMLA Script
                    Dts.Variables["User::CreatePartitions"].Value = ReadFile(CreatePartitionFileXMLA, errInfo);
                    if (errInfo.Length > 0)
                        Dts.Log("Error while reading XMLA file: " + errInfo, 0, dataByte);
                        Dts.TaskResult = (int)ScriptResults.Failure;
                    //Process XMLA Script
                    Dts.Variables["User::ProcessPartitions"].Value = ReadFile(ProcessPartitionFileXMLA, errInfo);
                    if (errInfo.Length > 0)
                        Dts.Log("Error while reading XMLA file: " + errInfo, 0, dataByte);
                        Dts.TaskResult = (int)ScriptResults.Failure;
                    Dts.TaskResult = (int)ScriptResults.Success;
                catch (Exception ex)
                    Dts.Log("Error Message: " + ex.Message, 0, dataByte);
                    Dts.TaskResult = (int)ScriptResults.Failure;
            public String ReadFile(String FilePath, String ErrInfo)
                String strContents;
                StreamReader sReader;
                try
                    sReader = File.OpenText(FilePath);
                    strContents = sReader.ReadToEnd();
                    sReader.Close();
                    return strContents;
                catch (Exception e)
                    MessageBox.Show(ErrInfo);
                    ErrInfo = e.Message;
                    return "";
     how to solve this issue
     pleasse help me..

    Hi sheshu0022,
    Based on my research, the issue can be occurred due to something get corrupted in the script task. To fix this issue, please copy the code in the task, then rebuild the script task with the same code to test again.
    The following similar thread is for your reference:
    http://stackoverflow.com/questions/15165760/ssis-script-task-fails-on-server-with-error-cannot-load-script-for-execution
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Cannot load script for the required change in butt...

    I got the email saying Skype will be changed after 15 March.  It says we need the new buttons.  So I go the site, and then there is a big box which says: "cut and paste this" which is:
    <script type="text/javascript" src="http://www.skypeassets.com/i/scom/js/skype-uri.js"></script>
    <div id="SkypeButton_Call_[Removed for privacy]_1">
    <script type="text/javascript">
    Skype.ui({
    "name": "call",
    "element": "SkypeButton_Call_[Removed for privacy]_1",
    "participants": ["[Removed for privacy]"],
    "imageSize": 32
    </script>
    </div>
    So where do I paste this script. Plus I get we need to do on our Ipads as well.

    Hi sheshu0022,
    Based on my research, the issue can be occurred due to something get corrupted in the script task. To fix this issue, please copy the code in the task, then rebuild the script task with the same code to test again.
    The following similar thread is for your reference:
    http://stackoverflow.com/questions/15165760/ssis-script-task-fails-on-server-with-error-cannot-load-script-for-execution
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • BR100 document for Order Management

    Hi
    If any one can share the BR100 document for Order Management module?
    Thanks in advance,
    Rajesh

    You can get this document by downloading AIM software.
    http://download-east.oracle.com/partners/265498.EXE
    The new version is available for download to Oracle Partners only
    http://www.oracle.com/partners/develop/implementation/global/aimfoundation.html

  • Batch load file for folder

    hi,
    I am using ucm10.1.3.3.3, the question is can I use batch load file for folders?
    There seems only primaryFile in loading definition file, this means I can only define loading files one by one, is there a way to define loading folders.
    I have millions of files within about 100 folders, if no loading folder function is available, what's your suggestion on this case?
    Thanks!
    Best regards

    Hi,
    If you want to replicate the local folder-structure with documents into UCM, I don't think BatchLoader can do that!
    Then either drag-n-drop or write some custom component that creates IdcCommand file for folder-creation as well as checking in documents into UCM folder.
    Regards,
    Prateek

  • How to process Fisacl year change for Investment Management with Project?

    How to process Fisacl year change for Investment Management with Project as measure

    hi
    check this menu path
    Accounting  --> Investment Management  --> Programs  --> Periodic Processing  --> Fiscal Year Change

  • Service Order Management with External ResourceProc.Presentation Req???????

    Hello All
    I want presentations about the scenario u201CService Order Management with External Resource Procurementu201D and if some one have implemented this scenario it will be much better if I got a detailed scenario
    Please send me the presentations and the documents to
    Jacopo.fransoice"at"live.com
    Thanks in advance
    Jacopo Fransoice

    i need these presentations urgently

  • Integration of BPEL Process Manager with Oracle Plociy Automation(OPA)

    Hi,
    Can any one tell me how to integrate the BPEL Process Manager with Oracle Plociy Automation(OPA).

    Hi,
    Can any one tell me how to integrate the BPEL Process Manager with Oracle Plociy Automation(OPA).

  • Need data loader script for Buyer Creation for R12

    Hi ,
    Anybody has data loader script for Buyer creation in R12. Please copy paste one line in the reply on this message.
    Thanks

    Hi ,
    Anybody has data loader script for Buyer creation in R12. Please copy paste one line in the reply on this message.
    Thanks

  • Load Scripts for stress testing any OAF related application

    This may not be the correct forum. However, i'm sure many of you might have used load scripts to stress test your OAF related application.
    Can any of please shed some light on how to make these load scripts for automated testing for finding the performance of OAF appls (like iPro or iExpense)? What tool do we use for these type of Self Serv appls? How can we parameterise some of the session related values inside load scripts?
    Any of your experiences will give me a good start....Thanks

    Answers to these questions are generally dependent on the application server to which you will be deploying, as each application server has its own means of tuning for performance.
    For tuning Sun's App Server 8, see the online Performance Tuning Manual, at http://docs.sun.com/app/docs/doc/819-2561
    // Gregory

Maybe you are looking for

  • How do I use multiple accounts on the same Mac with Apple TV2?

    I have home sharing turned on in two separate accounts on a single MacPro.  When I am logged into both accounts, I can see both accounts' iTunes Libraries available in the AppleTV2.  However, when I try to open each account iTunes Library in the Appl

  • Dark Side of the Moon inspired wallpapers ~

    Hi friends, i've finish this wallpaper, i hope this is the first of a few series. For those linux and Pink Floyd 'users'. Enjoy! Link and more resolutions here Thanks in advance! iamgabo ~

  • Infotype 0008 using SEQNR?

    Hi, Anyone here have gone down the path of using SEQNR on infotype 0008? Is it possible to do so? For example, a person transfering from LA to London received a position promotion increase, cost of living adjustment, and internal equity adjustment. T

  • Setup system check says internet explorer is open when it's not

    When I get to the setup screen (for the trial version of Illustrator), the first thing is system check. It says my internet explorer is open, and it's not. I've closed all programs that use internet including all of my antivirus and spyware, my vista

  • Twitter opens but my stream won't appear

    ''Duplicate post, continue here - [https://support.mozilla.com/en-US/questions/789987]'' When I use FIREFOX to get to my Twitter page,Home page opens but my timeline stream doesn't appear. I can't click on my 'settings' either, even though it's on th