MULTIORG SETUP후 ORG_ID = NULL 인 데이타가 존재할 때

제품 : AOL
작성날짜 : 2003-05-14
MULTIORG SETUP후 ORG_ID = NULL 인 데이타가 존재할 때
============================================
PURPOSE
MULTIORG SETUP후 ORG_ID = NULL 인 데이타의 해결
Problem Description
1. Run script to check Multi-Org is enabled:
          SELECT multi_org_flag
          FROM fnd_product_groups;
2. Check that Profile Option MO: Operating unit is set
3. Run script to see how many rows have org_id=NULL
          SELECT count(*) from AR_SYSTEM_PARAMETERS_ALL
          WHERE ORG_ID is null;
Workaround
Solution Description
adadmin에서 multi-org 를 enable하시전에
Profile Option에서 MO:Operating Unit 에 값을 넣고
작업을 진행하면 된다.
Reference Documents
Note 163537.1

Similar Messages

  • LOCATOR CONTROL품목이 NULL로 입고되었을 때 DATAFIX방법

    제품 : MFG_INV
    작성날짜 : 2005-05-30
    LOCATOR CONTROL품목이 NULL로 입고되었을 때 DATAFIX방법
    ==========================================
    PURPOSE
    Locator Control이 "Prespecified"로 setup되어 있음에도 불구하고,
    Locator=NULL로 입고되는 Inventory Itemd에 대한 datafix방법을
    제시하고자 합니다.
    Explanation
    Valid Locator ID로 다음 Table들에 Update작업을 수행하여야 합니다.
    (1) MTL_MATERIAL_TRANSACTIONS
    update MTL_MATERIAL_TRANSACTIONS
    set locator_id = <valid locator id)
    where transaction_id= &trxid
    and locator_id is NULL
    =====================================
    (2) MTL_ONHAND_QUANTITIES_DETAIL
    update MTL_ONHAND_QUANTITIES
    set locator_id = <valid locator id)
    where inventory_item_id=&itemid
    and organization_id = &orgid
    and subinventory_code = &subcode
    and locator_id is NULL
    =======================================
    (3) RCV_TRANSACTIONS
    update RCV_TRANSACTIONS
    set locator_id = <valid locator id)
    where transaction_id= &trxid
    and locator_id is NULL
    Example
    Reference Documents
    Note:181604.1

  • How to open a JPanel

    Hi
    I have created a JPanel in JDeveloper 10.1.3. It has a main method with (see below) but when opened from my application I must use something else than JUTestFrame but what? How should the JPanel be opened the right way?
    public static void main(String [] args) {
    try {
    UIManager.setLookAndFeel("com.jgoodies.looks.plastic.PlasticXPLookAndFeel");
    } catch (ClassNotFoundException cnfe) {
    try {
    UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
    } catch (Exception exemp) {
    exemp.printStackTrace();
    } catch (Exception exemp) {
    exemp.printStackTrace();
    CurrencyRateEdit panel = new CurrencyRateEdit();
    panel.setBindingContext(JUTestFrame.startTestFrame("mypackage.DataBindings.cpx", "null", panel, panel.getPanelBinding(), new Dimension(400,300)));
    panel.revalidate();
    }

    Thanks for the input, unfortunately using the JFrame provided by the JDev wizard is what we are trying to avoid. We do not want a JFrame of any kind.
    I have it working now with a JPanel as the top level container for the ADF plumbing. This allows me to place the ADF bindings virtually anywhere without any type of boarders. Here is how I did it. (by the way I am still testing out Erik's recommendation)
    1) create a default application with an empty runable panel. (the main() can be moved out later but makes it easy for testing) The code here assumes you are using all the default naming in the wizard. If not you will have to make the appropriate changes.
    2) Just under the class definition create an instance of a class named "appPanel". This class will be defined below and is a gutted/modified version of JUTestFrame which extends JPanel instead of JFrame. It should look something like this:
    public class Panel1 extends JPanel implements JUPanel {       
    public appPanel canvas = new appPanel();
    3) In the main() function change
    panel.setBindingContext(JUTestFrame.startTestFrame( ...
    to:
    panel.setBindingContext(panel.canvas.startTestFrame( ... //canvas is the name I chose in step 2.
    4) If, in this test app, you don't already have a container (JForm or other) for the ADF JPanel you can create one for testing like this:
    At the bottom of the main() function put :
    JFrame xx = new JFrame();
    xx.add(panel);
    xx.setVisible(true);
    5) Create the class file appPanel (menu: new >simple file > Java Class. and replace all of the contents with: (excuse the formatting. I don't know why they don't make developer forums more code friendly)
    package mypackage;
    import java.awt.Dimension;
    import java.awt.Toolkit;
    import java.awt.GridLayout;
    import java.awt.event.KeyEvent;
    import java.beans.PropertyVetoException;
    import javax.swing.JPanel;
    import javax.swing.JInternalFrame;
    import javax.swing.JScrollPane;
    import java.util.HashMap;
    import oracle.jbo.uicli.UIMessageBundle;
    import oracle.jbo.uicli.jui.JUPanelBinding;
    import oracle.jbo.uicli.jui.JUEnvInfoProvider;
    import oracle.jbo.uicli.controls.JUErrorHandlerDlg;
    import oracle.jbo.uicli.controls.JClientPanel;
    import oracle.jbo.uicli.binding.JUApplication;
    import oracle.jbo.uicli.mom.JUMetaObjectManager;
    import oracle.adf.model.BindingContext;
    import oracle.adf.model.DataControlFactory;
    import oracle.adf.model.binding.DCDataControl;
    import oracle.jbo.uicli.controls.*;
    public class appPanel extends JPanel
    private JUPanelBinding panelBinding = null;
    private DCDataControl dataControl;
    private BindingContext mCtx;
    appPanel frame;
    public appPanel() {
    try {
    jbInit();
    } catch (Exception e) {
    e.printStackTrace();
    public BindingContext startTestFrame(String cpxName, String dcName, JPanel panel, JUPanelBinding panelBinding, Dimension size)
    if (!(panel instanceof JUPanel))
    System.err.println(UIMessageBundle.getResString(UIMessageBundle.STR_TUI_ERROR_JCLIENTPANEL));
    return null;
    frame = new appPanel(cpxName, dcName, panelBinding, panel);
    frame.adjustFrameSize(size);
    return frame.getBindingContext();
    public appPanel(JUPanelBinding designTimePanelBinding, JPanel panel)
    this.setLayout(new GridLayout());
    JScrollPane scPane = new JScrollPane(panel);
    this.add(scPane);
    JUMetaObjectManager.setBaseErrorHandler(new JUErrorHandlerDlg());
    //mom will pass properties in case it's null
    JUApplication app = JUMetaObjectManager.createApplicationObject(designTimePanelBinding.getApplicationName(), null, new JUEnvInfoProvider());
    panelBinding = new JUPanelBinding(designTimePanelBinding.getApplicationName(), panel);
    panelBinding.setApplication(app);
    ((JClientPanel)panel).setPanelBinding(panelBinding);
    panelBinding.execute();
    dataControl = app;
    public appPanel(String cpxName, String dcName, JUPanelBinding panelBinding, JPanel panel)
    this.setLayout(new GridLayout());
    JScrollPane scPane = new JScrollPane(panel);
    this.add(scPane);
    createBindingCtxAndSetUpMenu(cpxName, dcName, panelBinding);
    private void createBindingCtxAndSetUpMenu(String cpxName, String dcName, JUPanelBinding panelBinding)
    JUMetaObjectManager.setBaseErrorHandler(new JUErrorHandlerDlg());
    JUMetaObjectManager.getJUMom().setJClientDefFactory(null);
    mCtx = new BindingContext();
    HashMap map = new HashMap(4);
    map.put(DataControlFactory.APP_PARAMS_BINDING_CONTEXT, mCtx);
    JUMetaObjectManager.loadCpx(cpxName, map);
    DCDataControl app = (DCDataControl)mCtx.get(dcName);
    if (app != null)
    dataControl = app;
    app.setClientApp(DCDataControl.JCLIENT);
    else
    mCtx.setClientAppType(DCDataControl.JCLIENT);
    panelBinding = panelBinding.setup(mCtx, null);
    public DCDataControl getDataControl()
    return dataControl;
    public BindingContext getBindingContext()
    return mCtx;
    void adjustFrameSize(Dimension size)
    setSize(size);
    Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
    if (size.height > screenSize.height)
    size.height = screenSize.height;
    if (size.width > screenSize.width)
    size.width = screenSize.width;
    setLocation((screenSize.width - size.width) / 2, (screenSize.height - size.height) / 2);
    setVisible(true);
    private static final char MNEMONICINDICATOR = '&';
    public static final int MNEMONIC_INDEX_NONE = -1;
    * Returns the key code for the mnemonic in the string. Returns
    * VK_UNDEFINED if the string does not contain a mnemonic.
    public int getMnemonicKeyCode(String string)
    if (string == null)
    return KeyEvent.VK_UNDEFINED;
    // Minus one, because a trailing ampersand doesn't count
    int lengthMinusOne = string.length() - 1;
    int i = 0; // Index in the source sting
    while (i < lengthMinusOne)
    int index = string.indexOf(_MNEMONIC_INDICATOR, i);
    // Are we at the end of the string?
    if ((index == -1) || (index >= lengthMinusOne))
    break;
    char ch = string.charAt(index + 1);
    // if this isn't a double ampersand, return
    if (ch != MNEMONICINDICATOR)
    // VK_* constants are all for upper case characters
    return(int) Character.toUpperCase(ch);
    // Skip over the double ampersand
    i = index + 2;
    return KeyEvent.VK_UNDEFINED;
    * Removes non-displayable inline mnemonic characters.
    * In order to specify a mnemonic character in a translatable string
    * (eg. in a resource file), a special character is used to indicate which
    * character in the string should be treated as the mnemonic. This method
    * assumes that an ampersand ('&') character is used as the mnemonic
    * indicator, and removes (single) ampersands from the input string. A
    * double ampersand sequence is used to indicate that an ampersand should
    * actually appear in the output stream, in which case one of the ampersands
    * is removed.
    * Clients should call this method after calling
    * StringUtils.getMnemonicIndex() and before displaying the string. The
    * returned string should be used in place of the input string when
    * displaying the string to the end user. The returned string may be the
    * same as the input string if no mnemonic indicator characters are found,
    * but this is not guaranteed.
    * @see #getMnemonicIndex
    public String stripMnemonic(String string)
    if (string == null)
    return null;
    int length = string.length();
    // Single character (or empty) strings can't have a mnemonic
    if (length <= 1)
    return string;
    StringBuffer buffer = null;
    int i = 0;
    while (i < length)
    int index = string.indexOf(_MNEMONIC_INDICATOR, i);
    // We've reached the append. Append the rest of the
    // string to the buffer, if one exists, then exit
    if ((index < 0) || (index >= length - 1))
    if (buffer != null)
    buffer.append(string.substring(i));
    break;
    if (buffer == null)
    // If the string starts with an ampersand, but not a double
    // ampersand, then we just want to return
    // stripMnemonic(string.substring(1)). This is basically
    // what we do here, only I've optimized the tail recursion away.
    if ((index == 0) && (string.charAt(1) != MNEMONICINDICATOR))
    string = string.substring(1);
    length--;
    continue;
    else
    // Allocate the buffer. We can reserve only space
    // (length - 1), because, by now, we know there's at least
    // 1 ampersand
    buffer = new StringBuffer(length - 1);
    // Append the bits of the string before the ampersand
    buffer.append(string.substring(i, index));
    // And append the character after the ampersand
    buffer.append(string.charAt(index + 1));
    // And skip to after that character
    i = index + 2;
    // If we never allocated a buffer, then there's no mnemonic
    // at all, and we can just return the whole string
    if (buffer == null)
    return string;
    return new String(buffer);
    private void jbInit() throws Exception {
    And now you have an ADF implementation that exists purely in a JPanel to be placed anywhere.
    Again I am still testing Erik's recomendation which may prove to be a better implementation; but I wanted to share what I have working.
    I hope this helps someone out. Good luck.
    SMartel

  • Get  max100 requests from request manager

    Hello!
    I'm requesting requests for a user from the RequestManager over the ContentServices-API.
    Now I've the question if there is possibility to get maximal 100 requests? I've tried to set the Options.RETURN_COUNT and give that to the request manager, but that doesn't work. I only get an ParameterError.
    Any ideas?

    fnd_concurrent_requests has responsibility_id. You can use this column to determine the ORG_ID.
    However this may not always correct, as user may change the profile option after running the request. But in your environment if this profile option is not changed after it first assigned to responsibility then following sql should give you ORG_ID from concurrent request.
    select fnd_profile.VALUE_SPECIFIC('ORG_ID',null, RESPONSIBILITY_ID ,null,null,null) from fnd_concurrent_requests where request_id = <your_request_id>
    HTH
    Dinesh S.

  • R12 not able to load supplier contact

    Hi
    Instance : R12.1.3, Not able to upload the supplier contact details. using the conc program "Supplier Site Contacts Open Interface Import"
    the conc program is publishing the report with "no data found" when the conc program is completed normal.
    observation
    the table AP_SUP_SITE_CONTACT_INT is having null value for the column - REJECT_CODE
    inserted the data for following columns
    last_name, org_id, vendor_id, vendor_site_id,vendor_contact_interface_id,area_Code, phone number
    using the below
    INSERT INTO ap_sup_site_contact_int
    (vendor_site_id, vendor_site_code, -- One or the other is required
    org_id, operating_unit_name, -- One or the other is required
    first_name, last_name, prefix, title, mail_stop, area_code,
    phone, department, status, email_address, url, alt_area_code,
    alt_phone, fax_area_code, fax, vendor_id, vendor_contact_interface_id)
    VALUES (<Vendor_Site_ID>, NULL,
    <Org_ID>, NULL,
    '<Firstname>', '<Lastname>', NULL, NULL, NULL, '999',
    '999-9999', NULL, 'NEW', NULL, NULL, NULL,
    NULL, NULL, NULL, <Vendor_ID>, AP_SUP_SITE_CONTACT_INT_S.NextVal)
    Pls advice
    Regards
    Yram

    Hello,
    What error did you get when loading Page assets in a Recommendation asset?
    What is your WebCenter Sites version? If you are using 11.1.1.6.x, maybe you are experiencing the issue documented in KM Note 1531160.1.

  • Paramerterized Interactive Reports - is there a quick solution to stop the query from executing when entering the page prior to user clicking go.

    Example
    Currently, when the user enters the page the interactive report runs (without the user hitting "go")and - indicates no data found because one of the "parameterized" fields is required and the sql is not setup for nulls.
    I'm Looking for a way to not perform a query  at all -------until the user hits go for the first time on the page - then each time they re-enter the page in the same session it would be ok to auto submit the query.
    I believe I can setup a hidden item and check on my interactive report E1 not null.  Then create a "computation" on "after submission" that would set this value to a value - say 1.
    I can seem to be able to get this to work however.
    In my interactive report - I'm wondering what "condition type" should I be using.  Any thoughts would be greatly appreciated.

    In this case I just have 2 parameters.  The goal is to allow the user to "pre filter" BEFORE rendering the interactive due to the possible size of the report.  This pre fliter could be by say- order type or region or branch etc.
    Right now, I believe its all one region - see below.
    My first attempt, I put a branch on the after submit on the go button and then put a condition on the interactive report.  This worked but caused a looping issue when trying to select a column on the interactive report itself.  My guess is , because that drop down was also using that same go button.
    Anyway, please advise how to best  "pre filter" prior to rendering an interactive report.  Should I have two seperate regions or can I use one region.  Any assistance would be greatly appreciated. 
    Order Parameters 2 
    Before Header 
    Branches
    Computations
    Processes
    After Header 
    Computations
    Processes
    Regions
    Before Regions 
    Computations
    Processes
    Regions 
    Body (3) 
    Search 
    Items 
    P6_TEXT
    P6_ITEM_NUMBER
    Region Buttons  P6_GO
    Order Type &P6_TEXT 
    Report Columns 
    Order Type
    Operating Unit
    Order Number
    Line Number
    Item Number
    Invoice Week
    Items 
    P6_NAME
    P6_ITEM_NUMBER_ALT
    Position 01  Breadcrumbs
    After Regions 
    Computations
    Processes

  • Cost Based Query

    i have removed the RULE hints and tried the below query in 2 different databases both same version(10g)
    In one of the database query completed in 4hrs and in another database it completed in 3 days.
    Both databases has similar data.
    where i am doing wrong?
    Any feeedbacks?
    Any optimizer parameters needs to be set?
    lect /*+ RULE */ 'PO_COMMITMENT' record_type,
    b.org_id,
    NULL invoice_number,
    a.PO_NUMBER,
    a.PO_REVISION,
    a.RELEASE_NUMBER,
    a.CREATION_DATE,
    a.APPROVED_DATE,
    b.NEED_BY_DATE,
    b.PROMISED_DATE,
    a.BUYER_NAME,
    a.VENDOR_NAME,
    a.PO_LINE,
    replace(a.ITEM_DESCRIPTION, chr(10),' ') item_description,
    a.QUANTITY_ORDERED,
    a.AMOUNT_ORDERED,
    a.QUANTITY_CANCELLED,
    a.AMOUNT_CANCELLED,
    a.QUANTITY_DELIVERED,
    a.AMOUNT_DELIVERED,
    a.QUANTITY_INVOICED ,
    a.AMOUNT_INVOICED*nvl(pod.rate,1) AMOUNT_INVOICED,
    a.Amount_outstanding_invoice,
    a.PROJECT_ID,
    a.TASK_ID,
    a.EXPENDITURE_ITEM_DATE,
    a.ACCT_EXCHANGE_RATE,
    a.denom_CURRENCY_CODE,
    a.PO_HEADER_ID,
    a.PO_RELEASE_ID,
    pod.po_line_id REQUISITION_HEADER_ID,
    a.po_line_location_id REQUISITION_LINE_ID ,
    pod.po_distribution_id invoice_id,
    EXPENDITURE_ORGANIZATION ,
    null po_status,
    pod.accrue_on_receipt_flag po_line_status,
    null requisioner_name,
    0 commitment_amt,
    pod.po_header_id xpo_header_id,
    pod.po_distribution_id xpo_distribution_id,
    pod.distribution_num DISTRIBUTION_LINE_NUMBER
    from pa_proj_appr_po_distributions a,
    po_distributions pod,
    po_line_locations b
    where a.PO_LINE_LOCATION_ID = b.LINE_LOCATION_ID
    and a.po_distribution_id = pod.po_distribution_id
    and b.line_location_id = pod.line_location_id
    and b.org_id = :p_org_id
    and a.project_id > 0
    UNION ALL
    SELECT /*+ RULE */ 'REQ_COMMITMENT' ,
    :p_org_id,
    NULL,
    REQ_NUMBER ,
    NULL ,
    NULL,
    CREATION_DATE ,
    to_date(null),
    NEED_BY_DATE ,
    to_date(null),
    null,
    vendor_name,
    REQ_LINE ,
    replace(ITEM_DESCRIPTION, chr(10), ' '),
    QUANTITY ,
    AMOUNT ,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    PROJECT_ID ,
    TASK_ID ,
    EXPENDITURE_ITEM_DATE ,
    ACCT_EXCHANGE_RATE ,
    denom_CURRENCY_CODE,
    0,
    0,
    REQUISITION_HEADER_ID,
    REQUISITION_LINE_ID ,
    0 invoice_id,
    EXPENDITURE_ORGANIZATION ,
    null po_status,
    null po_line_status,
    REQUESTOR_NAME requisioner_name,
    AMOUNT ,
    0,
    0,
    0 DISTRIBUTION_LINE_NUMBER
    FROM pa_proj_appr_req_distributions
    union all
    select /*+ RULE */ 'INVOICE_COMMITMENT' ,
    :p_org_id,
    b.INVOICE_NUM,
    NULL,
    NULL,
    NULL,
    b.creation_date,
    a.INVOICE_DATE,
    a.GL_DATE ,
    to_date(null),
    NULL,
    a.VENDOR_NAME,
    0,
    replace(a.DESCRIPTION,chr(10),' '),
    0,
    0,
    0,
    0,
    0,
    0,
    a.QUANTITY,
    a.AMOUNT ,
    0,
    a.PROJECT_ID ,
    a.TASK_ID ,
    a.EXPENDITURE_ITEM_DATE ,
    a.ACCT_EXCHANGE_RATE ,
    a.denom_CURRENCY_CODE ,
    0,
    0,
    aid.po_distribution_id,
    aid.invoice_distribution_id,
    a.invoice_id,
    a.EXPENDITURE_ORGANIZATION ,
    null,
    null,
    null,
    a.amount ,
    0,
    0,
    a.DISTRIBUTION_LINE_NUMBER
    FROM
    pa_proj_ap_inv_distributions a,
    ap_invoices b,
    ap_invoice_distributions aid
    where a.invoice_id = b.invoice_id
    and aid.invoice_id = b.invoice_id
    and a.distribution_line_number = aid.distribution_line_number

    Hello,
    It's duplicate post, please close this and provide requested information in your previous post.
    Regards

  • Creation of item from High Volumn Repair of Depot Repair(Custom Region)

    hi,
    Take the first job for the current repair order
    Query:
    Select WIP_ENTITY_ID from CSD_REPAIR_JOB_XREF
    Where REPAIR_LINE_ID = < Current repair line_id> Order By CREATION_DATE Asc
    Take the entered component part number and search in the WIP job material requirements. This should use a WIP API. If the material is found, increment the quantity. If material is not found, create the job material using public API. (Provide WIP API details)
    Take the first job for the current repair order
    - Query:
    Select WIP_ENTITY_ID from CSD_REPAIR_JOB_XREF
    Where REPAIR_LINE_ID = < Current repair line_id> Order By CREATION_DATE Asc
    - Take the entered component part number and search in the WIP job material requirements.
    - Query:
    Select 1 from CSD_WIP_TRANSACTION_DETAILS where Inventory_item_id = <Component Part Num> and inventory_org_id = <Repair inventory org id>
    - If record found update CSD_WIP_TRANSACTION_DETAILS and increment TRANSACTION_QTY
    - Else insert into CSD_WIP_TRANSACTION_DETAILS
    - Call CsdHvWipJobPvtEOImpl .processSaveMtlTxnDtls to create records in MTI(MTL_TRANSACTIONS_INTERDFACE)
    - Call CsdHvWipJobPvtEOImpl.processIssueMtlTxn to issue the materials added to wip job.
    The java object, oracle.apps.csd.schema.server .CsdHvWipJobPvtEO is a wrapper to call WIP API. This should be used to create material requirements.
    the AM code of OA Framework
    public void insertMaterial(String concat_segm ,String invent_item ,String organ_id,String wip_Entity){
    Number wip_entity_id =null,inventory_item_id=null,org_id =null;
    OADBTransaction oadbtransaction = (OADBTransaction)getTransaction();
    String repairLineId =
    (String)oadbtransaction.getValue("csdRepairLineId");
    try{
    wip_entity_id =new Number(wip_Entity);
    inventory_item_id =new Number(invent_item);
    org_id =new Number(organ_id);
    }catch(SQLException e ){e.printStackTrace();}
    OADBTransaction transaction = getOADBTransaction();
    Number wipTransDetailsId = transaction.getSequenceValue("CSD_WIP_TRANSACTION_DETAILS_S1");
    CsdHvWipJobPvtEOImpl localCsdHvWipJobPvtEOImpl = null;
    AttributeList localAttributeList = null;
    ArrayList arraylist = new ArrayList();
    localCsdHvWipJobPvtEOImpl = (CsdHvWipJobPvtEOImpl)((OAEntityDefImpl)CsdHvWipJobPvtEOImpl.getDefinitionObject()).createInstance(getOADBTransaction(), localAttributeList);
    String as[] = {
    Number anumber[] = {
    new Number(0)
    String as1[] = {
    String as2[] = {
    oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec mtltxndtlsrec = new oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec();
    mtltxndtlsrec.transaction_quantity = new Number(1);
    mtltxndtlsrec.transaction_uom = String.valueOf("Ea");
    mtltxndtlsrec.serial_number = String.valueOf("");
    mtltxndtlsrec.wip_transaction_detail_id = wipTransDetailsId;
    mtltxndtlsrec.inventory_item_id =inventory_item_id;
    mtltxndtlsrec.wip_entity_id = wip_entity_id;
    mtltxndtlsrec.operation_seq_num = new Number(10);
    mtltxndtlsrec.object_version_number = new Number(1);
    mtltxndtlsrec.new_row = "Y";
    mtltxndtlsrec.organization_id = new Number(207);
    mtltxndtlsrec.supply_subinventory =String.valueOf("RIP");
    arraylist.add(mtltxndtlsrec);
    oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec amtltxndtlsrec[] = new oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec[arraylist.size()];
    Iterator iterator = arraylist.iterator();
    int k = 0;
    while(iterator.hasNext())
    amtltxndtlsrec[k++] = (oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec)iterator.next();
    Number number1 = null;
    Number number2 = null;
    try
    number1 = new Number(1.0D);
    catch(Exception exception) { }
    try
    number2 = new Number(100);
    catch(Exception exception1) { }
    try
    {  System.out.println("before  processSaveMtlTxnDtls call");
    //CsdHvWipJobPvtEOImpl csdhvwipjobpvteoimpl =new CsdHvWipJobPvtEOImpl();
    CsdHvWipJobPvtEOImpl.processSaveMtlTxnDtls(getOADBTransaction(), number1, "T", "F", number2, as, anumber, as1, amtltxndtlsrec, as2);
    System.out.println("after processSaveMtlTxnDtls call");
    getTransaction().commit();
    catch(SQLException sqlexception) { }
    Number bnumber[] = {
    null
    try
    number1 = new Number(100);
    catch(Exception exception1) { }
    Number anumber1[] = {
    new Number(0)
    ArrayList arraylist1 = new ArrayList();
    mtltxndtlsrec.serial_number_control_code =new Number(5);
    mtltxndtlsrec.lot_control_code = new Number(1);
    mtltxndtlsrec.revision_qty_control_code = new Number(1);
    mtltxndtlsrec.supply_subinventory = String.valueOf("RIP");
    mtltxndtlsrec.uom_code = String.valueOf("Ea");
    mtltxndtlsrec.supply_locator_id = new Number(156);
    mtltxndtlsrec.required_quantity = new Number(1);
    mtltxndtlsrec.issued_quantity = new Number(1);
    mtltxndtlsrec.job_quantity = new Number(0);
    arraylist1.add(mtltxndtlsrec);
    oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec amtltxndtlsrec1[] = new oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec[arraylist1.size()];
    Iterator iterator1 = arraylist1.iterator();
    int j = 0;
    while(iterator1.hasNext())
    amtltxndtlsrec1[j++] = (oracle.apps.csd.schema.server.CsdHvWipJobPvtEOImpl.MtlTxnDtlsRec)iterator.next();
    Number number = null;
    try
    number = new Number(1.0D);
    catch(Exception exception) { }
    try {
    System.out.println("before processIssueMtlTxn call");
    CsdHvWipJobPvtEOImpl.processIssueMtlTxn(getOADBTransaction(), number, "T", "T", number1, as, anumber1, as1, amtltxndtlsrec, bnumber);
    System.out.println("before processIssueMtlTxn call");
    catch(SQLException sqlexception) { }
    }

    Thanks Rakesh.
    I had looked at this before but does not help for RMA process using sub-contracting repairs. I could now resolve my issues without having to use the task list at all. That SAP help link what i had used was causing my issues.
    Maanoj

  • Error: ORA-04030: out of process memory when trying to allocate 20060 bytes

    I have tow portioned of query and uniond all it it gives error like ORA-04030: out of process memory when trying to allocate 20060 bytes
    NOTE : PARTY ONE AND PART 2 INDUALY WORKS WELL BUTT IT GIVESS ERROR AT THE TIME OF UNION ALL
    Please i m waiting for sharp response
    -------------------------------------PART ONE START --------------------------------------------------------------------------
    SELECT * FROM
    SELECT
    TO_CHAR(SOURCE) AS SOURCE,
    ORG_ID,
    -- 'HUSSNAIN' AS VENDOR_TYPE,
    INV_PAY_VOUCHER,
    INV_PAY_TYPE,
    INV_PAY_NUM,
    INV_PAY_VEN_ID,
    INV_PAY_VEN_NAME,
    INV_PAY_SITE,
    INV_PAY_DATE,
    INV_PAY_GROSS,
    INV_PAY_AMT,
    INV_PAY_DESC,
    INV_PAY_HTAX,
    INV_AMT,
    INV_GST,
    INV_PAY_AMT INVOICE_AMOUNT,
    INV_GST_T INV_TOTAL_TAX,
    NVL(DEBIT,0) AS DEBIT1,
    NVL(CREDIT,0) AS CREDIT1,
    VENDOR_SITE_NAME AS SITE_CODE,
    INVOICE_DATE,
    CHECK_NUMBER,
    PAYMENT_DATE,
    GL_CODE,
    GL_CODE_DESC,
    SUPPLIER_ID,
    STATUS ,
    COUNT(INV_PAY_DATE) AS TRANSACTION,
    LINE,
    SELECT
    SUM(NVL(VX.DEBIT,0)) - SUM(NVL(VX.CREDIT,0)) OPN_BAL
    FROM XX_AP_INVPAY_COMBINE_V1 VX
    WHERE
    SUBSTR(VX.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    -- AND
    -- SUBSTR(VX.INVOICE_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD')
    AND VX.INV_PAY_SITE = nvl(:P_SITE_ID, VX.INV_PAY_SITE)
    AND VX.Vendor_Site_name = nvl(:P_VENDOR_SITE_NAME , VX.Vendor_Site_name)
    AND VX.INV_PAY_VEN_ID = nvl(:P_VEN_ID,INV_PAY_VEN_ID)
    AND VX.ORG_ID = nvl(:P_ORG_ID,ORG_ID)
    AND VX.SOURCE = NVL (:P_TRANSACTION_TYPE,VX.SOURCE)
    AND vx.status = 'Approved'
    AND VX.INV_PAY_SITE =V.INV_PAY_SITE
    AND VX.Vendor_Site_name=V.VENDOR_SITE_NAME
    AND VX.INV_PAY_VEN_ID=V.INV_PAY_VEN_ID
    and vx.status = v.status
    -- AND VX.SOURCE=V.SOURCE
    -- &pwhereclause
    ) AS O_BALANCE_APPROVED,
    SELECT
    SUM(NVL(VX.DEBIT,0)) - SUM(NVL(VX.CREDIT,0)) OPN_BAL
    FROM XX_AP_INVPAY_COMBINE_V1 VX
    WHERE
    SUBSTR(VX.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    -- AND
    -- SUBSTR(VX.INVOICE_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD')
    AND VX.INV_PAY_SITE = nvl(:P_SITE_ID, VX.INV_PAY_SITE)
    AND VX.Vendor_Site_name = nvl(:P_VENDOR_SITE_NAME , VX.Vendor_Site_name)
    AND VX.INV_PAY_VEN_ID = nvl(:P_VEN_ID,INV_PAY_VEN_ID)
    AND VX.ORG_ID = nvl(:P_ORG_ID,ORG_ID)
    AND VX.SOURCE = NVL (:P_TRANSACTION_TYPE,VX.SOURCE)
    and vx.status = 'Unapproved'
    AND VX.INV_PAY_SITE =V.INV_PAY_SITE
    AND VX.Vendor_Site_name=V.VENDOR_SITE_NAME
    AND VX.INV_PAY_VEN_ID=V.INV_PAY_VEN_ID
    and vx.status = v.status
    -- AND VX.SOURCE=V.SOURCE
    -- &pwhereclause
    ) AS O_BALANCE_UPAPPROVED,
    SELECT
    SUM(NVL(VX.DEBIT,0)) - SUM(NVL(VX.CREDIT,0)) OPN_BAL
    FROM XX_AP_INVPAY_COMBINE_V1 VX
    WHERE
    SUBSTR(VX.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    -- AND SUBSTR(VX.INVOICE_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD')
    AND VX.INV_PAY_SITE = nvl(:P_SITE_ID, VX.INV_PAY_SITE)
    AND VX.Vendor_Site_name = nvl(:P_VENDOR_SITE_NAME , VX.Vendor_Site_name)
    AND VX.INV_PAY_VEN_ID=nvl(:P_VEN_ID,INV_PAY_VEN_ID)
    AND VX.ORG_ID = NVL(:P_ORG_ID,ORG_ID)
    AND VX.SOURCE = NVL (:P_TRANSACTION_TYPE,VX.SOURCE)
    AND vx.status = v.status
    AND VX.INV_PAY_SITE =V.INV_PAY_SITE
    AND VX.Vendor_Site_name=V.VENDOR_SITE_NAME
    AND VX.INV_PAY_VEN_ID=V.INV_PAY_VEN_ID
    -- AND VX.SOURCE=V.SOURCE
    -- &pwhereclause
    ) AS O_BALANCE
    FROM XX_AP_INVPAY_COMBINE_V1 V
    WHERE
    SUBSTR (V.INV_PAY_DATE,1,10) BETWEEN NVL( TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD'),SUBSTR(V.INV_PAY_DATE,1,10)) AND nvl(TO_DATE(SUBSTR(:P_DATE2,1,10),'YYYY-MM-DD') ,SUBSTR(V.INV_PAY_DATE,1,10))
    -- AND
    -- SUBSTR(V.INVOICE_DATE,1,10) BETWEEN nvl( TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD'),SUBSTR(V.INVOICE_DATE,1,10)) AND nvl(TO_DATE(SUBSTR(:P_DATE_INVOICE2,1,10),'YYYY-MM-DD') ,SUBSTR(V.INVOICE_DATE,1,10))
    AND V.INV_PAY_SITE=nvl(:P_SITE_ID,INV_PAY_SITE)
    AND V.VENDOR_SITE_NAME = NVL(:P_VENDOR_SITE_NAME , V.VENDOR_SITE_NAME)
    AND V.INV_PAY_VEN_ID=nvl(:P_VEN_ID,V.INV_PAY_VEN_ID)
    AND V.ORG_ID=nvl(:P_ORG_ID,V.ORG_ID)
    AND V.SOURCE = NVL (:P_TRANSACTION_TYPE,V.SOURCE)
    -- ORDER BY INV_PAY_DATE,CHECK_NUMBER,INV_PAY_VOUCHER asc ,Debit1 desc ,credit1 DESC
    GROUP BY
    SOURCE,
    ORG_ID,
    -- 'HUSSNAIN' AS VENDOR_TYPE,
    INV_PAY_VOUCHER,
    INV_PAY_TYPE,
    INV_PAY_NUM,
    INV_PAY_VEN_ID,
    INV_PAY_VEN_NAME,
    INV_PAY_SITE,
    INV_PAY_DATE,
    INV_PAY_GROSS,
    INV_PAY_AMT,
    INV_PAY_DESC,
    INV_PAY_HTAX,
    INV_AMT,
    INV_GST,
    INV_PAY_AMT,
    INV_GST_T,
    DEBIT,
    CREDIT,
    VENDOR_SITE_NAME,
    INVOICE_DATE,
    CHECK_NUMBER,
    PAYMENT_DATE,
    GL_CODE,
    GL_CODE_DESC,
    SUPPLIER_ID,
    STATUS,
    LINE
    ORDER BY
    INV_PAY_DATE,
    CHECK_NUMBER,
    --V.SOURCE asc,
    INV_PAY_NUM,
    LINE,
    --INV_PAY_DESC,
    INV_PAY_VOUCHER
    ) A
    -------------------------------------PART ONE END --------------------------------------------------------------------------
    -------------------------------------PART TWO START --------------------------------------------------------------------------
    UNION ALL
    SELECT * FROM
    SELECT * FROM
    SELECT
    DISTINCT
    NULL AS SOURCE,
    ORG_ID,
    NULL AS INV_PAY_VOUCHER,
    NULL AS INV_PAY_TYPE,
    NULL AS INV_PAY_NUM,
    INV_PAY_VEN_ID,
    INV_PAY_VEN_NAME,
    INV_PAY_SITE,
    NULL AS INV_PAY_DATE,
    NULL AS INV_PAY_GROSS,
    NULL AS INV_PAY_AMT,
    NULL AS INV_PAY_DESC,
    NULL AS INV_PAY_HTAX,
    NULL AS INV_AMT,
    NULL AS INV_GST,
    NULL AS INVOICE_AMOUNT,
    NULL AS INV_TOTAL_TAX,
    NULL AS DEBIT1,
    NULL AS CREDIT1,
    NULL AS SITE_CODE,
    NULL AS INVOICE_DATE,
    NULL AS CHECK_NUMBER,
    NULL AS PAYMENT_DATE,
    NULL AS GL_CODE,
    NULL AS GL_CODE_DESC,
    SUPPLIER_ID,
    NULL AS STATUS ,
    NULL AS TRANSACTION,
    NULL AS LINE,
    SELECT
    SUM(NVL(VX.DEBIT,0)) - SUM(NVL(VX.CREDIT,0)) OPN_BAL
    FROM XX_AP_INVPAY_COMBINE_V1_OP VX
    WHERE
    SUBSTR(VX.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    -- AND
    -- SUBSTR(VX.INVOICE_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD')
    AND VX.INV_PAY_SITE = nvl(:P_SITE_ID, VX.INV_PAY_SITE)
    AND VX.Vendor_Site_name = nvl(:P_VENDOR_SITE_NAME , VX.Vendor_Site_name)
    AND VX.INV_PAY_VEN_ID = nvl(:P_VEN_ID,INV_PAY_VEN_ID)
    AND VX.ORG_ID = nvl(:P_ORG_ID,ORG_ID)
    AND VX.SOURCE = NVL (:P_TRANSACTION_TYPE,VX.SOURCE)
    AND vx.status = 'Approved'
    AND VX.INV_PAY_SITE =V.INV_PAY_SITE
    AND VX.Vendor_Site_name=V.VENDOR_SITE_NAME
    AND VX.INV_PAY_VEN_ID=V.INV_PAY_VEN_ID
    and vx.status = v.status
    -- AND VX.SOURCE=V.SOURCE
    -- &pwhereclause
    ) AS O_BALANCE_APPROVED,
    SELECT
    SUM(NVL(VX.DEBIT,0)) - SUM(NVL(VX.CREDIT,0)) OPN_BAL
    FROM XX_AP_INVPAY_COMBINE_V1_OP VX
    WHERE
    SUBSTR(VX.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    -- AND
    -- SUBSTR(VX.INVOICE_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD')
    AND VX.INV_PAY_SITE = nvl(:P_SITE_ID, VX.INV_PAY_SITE)
    AND VX.Vendor_Site_name = nvl(:P_VENDOR_SITE_NAME , VX.Vendor_Site_name)
    AND VX.INV_PAY_VEN_ID = nvl(:P_VEN_ID,INV_PAY_VEN_ID)
    AND VX.ORG_ID = nvl(:P_ORG_ID,ORG_ID)
    AND VX.SOURCE = NVL (:P_TRANSACTION_TYPE,VX.SOURCE)
    and vx.status = 'Unapproved'
    AND VX.INV_PAY_SITE =V.INV_PAY_SITE
    AND VX.Vendor_Site_name=V.VENDOR_SITE_NAME
    AND VX.INV_PAY_VEN_ID=V.INV_PAY_VEN_ID
    and vx.status = v.status
    -- AND VX.SOURCE=V.SOURCE
    -- &pwhereclause
    ) AS O_BALANCE_UPAPPROVED,
    (SUM(NVL(V.DEBIT,0)) - SUM(NVL(V.CREDIT,0))) AS O_BALANCE
    FROM XX_AP_INVPAY_COMBINE_V1_OP V
    WHERE
    SUBSTR(V.INV_PAY_DATE,1,10) < TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD')
    AND V.INV_PAY_SITE=nvl(:P_SITE_ID,INV_PAY_SITE)
    AND V.VENDOR_SITE_NAME = NVL(:P_VENDOR_SITE_NAME , V.VENDOR_SITE_NAME)
    AND V.INV_PAY_VEN_ID=nvl(:P_VEN_ID,V.INV_PAY_VEN_ID)
    AND V.ORG_ID=nvl(:P_ORG_ID,V.ORG_ID)
    AND
    ( (SELECT (SUM(NVL(V.DEBIT,0)) - SUM(NVL(V.CREDIT,0))) FROM XX_AP_INVPAY_COMBINE_V1_OP V
    WHERE
    SUBSTR (V.INV_PAY_DATE,1,10) BETWEEN NVL( TO_DATE(SUBSTR(:P_DATE1,1,10),'YYYY-MM-DD'),SUBSTR(V.INV_PAY_DATE,1,10)) AND nvl(TO_DATE(SUBSTR(:P_DATE2,1,10),'YYYY-MM-DD') ,SUBSTR(V.INV_PAY_DATE,1,10))
    -- AND
    -- SUBSTR(V.INVOICE_DATE,1,10) BETWEEN nvl( TO_DATE(SUBSTR(:P_DATE_INVOICE1,1,10),'YYYY-MM-DD'),SUBSTR(V.INVOICE_DATE,1,10)) AND nvl(TO_DATE(SUBSTR(:P_DATE_INVOICE2,1,10),'YYYY-MM-DD') ,SUBSTR(V.INVOICE_DATE,1,10))
    AND V.INV_PAY_SITE=nvl(:P_SITE_ID,INV_PAY_SITE)
    AND V.VENDOR_SITE_NAME = NVL(:P_VENDOR_SITE_NAME , V.VENDOR_SITE_NAME)
    AND V.INV_PAY_VEN_ID=nvl(:P_VEN_ID,V.INV_PAY_VEN_ID)
    AND V.ORG_ID=nvl(:P_ORG_ID,V.ORG_ID)
    AND V.SOURCE = NVL (:P_TRANSACTION_TYPE,V.SOURCE)) IS NULL
    GROUP BY
    ORG_ID,
    INV_PAY_VEN_ID,
    INV_PAY_VEN_NAME,
    INV_PAY_SITE,
    SUPPLIER_ID,
    V.VENDOR_SITE_NAME,
    V.STATUS
    --UNION ALL
    ) B
    -------------------------------------PART TWO END --------------------------------------------------------------------------

    Hi,
    This error is typically associated with the OS being unable to allocate any more memory to a process. It typically manifests itself in 32 bit operating systems, especially Windows, where processes are limited to a maximum 2Gb, but with the way memory is allocated, 1.5Gb tends to be a more realistic limit. With an Oracle instance this means that the total memory requirements, SGA and PGA, should not exceed about 1.5Gb. In Windows, because connection processes also run as threads of the server process, these are also part of the calculation.
    The way then to avoid, or at least reduce this error, is to reduce the memory requirements of the database instance. Also, because some operating systems do not release unused process memory very easily, regular bounces of the database may also help avoid the error, provided you have the luxury to do this.
    The long term fix to this error would be to upgrade to a 64 bit operating system, where this limit is greatly increased. There is also a feature of 32 bit windows that can be added (forget what its called) that increases the 2Gb limit to 3Gb.
    Regards
    Andre

  • System.Security.VerificationException: Operation could destabilize the runtime during code coverage run in visual studio

    I have a unit test that basically does the following:
    Creates an app domain using minimum priviledges.  The MarshalByRefObject that is living in the app domain, loads another assembly to execute.  This new assembly basically takes in a data object defined in a separate assembly, and returns a
    new data object of that type.
    All this works fine in debug mode, or when running w/out code coverage.  The Sandbox assembly is signed.
    The exception that gets thrown is this:
    Test method TestProject1.UnitTest1.TestMethod1 threw exception:
    System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Security.VerificationException: Operation could destabilize the runtime.
    ClassLibrary3.Bar..ctor()
    ClassLibrary2.Foo.TestMethod(Bar testBar)
    System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeType typeOwner)
    System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeType typeOwner)
    System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
    System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
    System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
    ClassLibrary1.RemoteSandBox.Execute(String assemblyPath, String scriptType, String method, Object[] parameters)
    ClassLibrary1.RemoteSandBox.Execute(String assemblyPath, String scriptType, String method, Object[] parameters)
    ClassLibrary1.SandBox.Execute(String assemblyPath, String scriptType, String method, Object[] parameters) in c:\users\la22426\documents\visual studio 2010\Projects\TestProject1\ClassLibrary1\Sandbox.cs: line 43
    TestProject1.UnitTest1.TestMethod1() in c:\users\la22426\documents\visual studio 2010\Projects\TestProject1\TestProject1\UnitTest1.cs: line 21
    Unit Test code:
    [TestClass]
    public class UnitTest1
    [TestMethod]
    public void TestMethod1()
    using (SandBox sandbox = new SandBox())
    string assemblyLocation = Path.Combine(Environment.CurrentDirectory, @"..\..\..\ClassLibrary2\bin\Debug\ClassLibrary2.dll");
    object result = sandbox.Execute(assemblyLocation, "ClassLibrary2.Foo", "TestMethod", new Bar() { X = "test" });
    Assert.IsNotNull(result);
    Data Object code:
    namespace ClassLibrary3
    [Serializable]
    public class Bar
    public Bar() { }
    public string X { get; set; }
    Assembly to execute code:
    namespace ClassLibrary2
    public class Foo
    public Bar TestMethod(Bar testBar)
    return new Bar() { X = testBar.X };
    Sandbox code:
    namespace ClassLibrary1
    public class SandBox : IDisposable
    AppDomain Domain { get; set; }
    RemoteSandBox RemoteSandBox { get; set; }
    public SandBox()
    var setup = new AppDomainSetup()
    ApplicationBase = AppDomain.CurrentDomain.BaseDirectory,
    ApplicationName = Guid.NewGuid().ToString(),
    DisallowBindingRedirects = true,
    DisallowCodeDownload = true,
    DisallowPublisherPolicy = true,
    //DisallowApplicationBaseProbing = true,
    var permissions = new PermissionSet(PermissionState.None);
    permissions.AddPermission(new SecurityPermission(SecurityPermissionFlag.Execution));
    permissions.AddPermission(new ReflectionPermission(PermissionState.Unrestricted));
    this.Domain = AppDomain.CreateDomain(setup.ApplicationName, null, setup, permissions,
    typeof(RemoteSandBox).Assembly.Evidence.GetHostEvidence<StrongName>());
    this.RemoteSandBox = (RemoteSandBox)Activator.CreateInstanceFrom(this.Domain, typeof(RemoteSandBox).Assembly.ManifestModule.FullyQualifiedName, typeof(RemoteSandBox).FullName).Unwrap();
    public object Execute(string assemblyPath, string scriptType, string method, params object[] parameters)
    return this.RemoteSandBox.Execute(assemblyPath, scriptType, method, parameters);
    public void Dispose()
    if (this.Domain != null)
    AppDomain.Unload(this.Domain);
    class RemoteSandBox : MarshalByRefObject
    public RemoteSandBox()
    public object Execute(string assemblyPath, string scriptType, string method, params object[] parameters)
    //we need some file io permissions to load the assembly
    new FileIOPermission(FileIOPermissionAccess.Read | FileIOPermissionAccess.PathDiscovery, assemblyPath).Assert();
    Assembly assembly;
    try
    assembly = Assembly.LoadFile(assemblyPath);
    finally
    CodeAccessPermission.RevertAssert();
    Type type = assembly.GetType(scriptType, true);
    MethodInfo methodInfo = type.GetMethod(method);
    object instance = (methodInfo.IsStatic) ? null : Activator.CreateInstance(type);
    object returnVal = null;
    returnVal = methodInfo.Invoke(instance, parameters);
    return returnVal;

    I marked the shared data library with the attributes:
    [assembly: AllowPartiallyTrustedCallers]
    [assembly: SecurityRules(SecurityRuleSet.Level2, SkipVerificationInFullTrust = true)]
    And then marked  the data class Bar with the attribute:
    [SecuritySafeCritical]
    And got a little more insight into what's going on:
    Test method TestProject1.UnitTest1.TestMethod1 threw exception:
    System.MethodAccessException: Attempt by security transparent method 'Microsoft.VisualStudio.Coverage.Init_d2f466df4c65e2a7bb5d7592c49efef0.Register()' to call native code through method 'Microsoft.VisualStudio.Coverage.Init_d2f466df4c65e2a7bb5d7592c49efef0.VSCoverRegisterAssembly(UInt32[],
    System.String)' failed.  Methods must be security critical or security safe-critical to call native code.
    Microsoft.VisualStudio.Coverage.Init_d2f466df4c65e2a7bb5d7592c49efef0.Register()
    ClassLibrary3.Bar..ctor() in c:\users\xxx\documents\visual studio 2010\Projects\TestProject1\ClassLibrary3\Bar.cs: line 13
    TestProject1.UnitTest1.TestMethod1() in c:\users\xxx\documents\visual studio 2010\Projects\TestProject1\TestProject1\UnitTest1.cs: line 21
    Since the injected code coverage il is doing some native stuff, it's throwing.  Any ideas on how to allow this?

  • GL REPORTS IN DISCOVERER

    hI Group,
    i am new to discoverer ,i have a client requirement here,
    requirement is:
    they have a report in gl called 'general ledger detail % horizantal'( it is develop with reports 6i)
    i have to translate this into oracle discoverer
    query-->
    SELECT A.NAME NAME,
    A.JHI JHI,
    A.account_num account_num,
    A.DESCRIPTION DESCRIPTION,
    A.category category,
    a.seq_num1 seq_num1,
    a.lseq lseq,
    a.cat_name cat_name,
    A.location location,
    A.division division,
    A.acc_desc acc_desc,
    A.source source,
    A.je_line_num je_line_num,
    A.Accounted_Date Accounted_Date,
    A.entry entry,
    A.batch batch,
    A.naration naration,
    A.LSequence LSequence,
    A.Document_num Document_num,
    A.LLine LLine,
    A.debit debit,
    A.credit credit,
    A.ent_dr ent_dr,
    A.ent_cr ent_cr,
    A.reference reference,
    A.ref2 ref2,
    A.ref3 ref3,
    A.reference_1 reference_1,
    A.reference_2 reference_2,
    A.reference_3 reference_3,
    A.transaction_no transaction_no,
    A.reference_5 reference_5,
    A.reference_6 reference_6,
    A.reference_7 reference_7,
    A.reference_8 reference_8,
    A.reference_9 reference_9,
    A.reference_10 reference_10,
    A.seq_id seq_id,
    A.seq_NUM seq_NUM,
    A.h_seq_id h_seq_id,
    A.gl_sl_link_id gl_sl_link_id,
    A.ae_line_id ae_line_id,
    A.gl_code_id gl_code_id,
    A.org_id org_id,
    A.org_name org_name
    FROM (select
    jh.NAME,
    JH.JE_HEADER_ID JHI ,
    nvl(gcc.SEGMENT4,0) account_num,
    nvl(ffv.DESCRIPTION,0) DESCRIPTION,
    decode(jc.je_category_name,'7','JV','8','JV','9','JV','10','JV','11','JV','12','JV','13','JV',jc.je_category_name)category,
    decode(jc.je_category_name,'7',jh.doc_sequence_value,'8',jh.doc_sequence_value,'9',jh.doc_sequence_value,'10',jh.doc_sequence_value,'11',jh.doc_sequence_value,'12',jh.doc_sequence_value,'13',jh.doc_sequence_value,ir.subledger_doc_sequence_value)seq_num1,
    decode(jc.je_category_name,'7',jc.USER_JE_CATEGORY_NAME ,'8',jc.USER_JE_CATEGORY_NAME,'9',jc.USER_JE_CATEGORY_NAME,'10',jc.USER_JE_CATEGORY_NAME,'11',jc.USER_JE_CATEGORY_NAME,'12',jc.USER_JE_CATEGORY_NAME,'13',jc.USER_JE_CATEGORY_NAME, ds.name)lseq,
    jc.USER_JE_CATEGORY_NAME cat_name,
    nvl(gcc.SEGMENT1 ,0) location,
    nvl(gcc.SEGMENT2,0) division,
    ffv.DESCRIPTION acc_desc,
    jh.je_source source,
    ir.je_header_id je_header_id,
    ir.je_line_num je_line_num,
    jl.effective_date Accounted_Date,
    jh.name entry,
    jh.je_batch_id batch,
    substr(jl.description,1,250)naration,
    ds.name LSequence,
    jh.doc_sequence_value Document_num,
    jl.je_line_num LLine,
    nvl(jl.accounted_dr,0) debit,
    nvl(jl.accounted_cr ,0) credit,
    jl.ACCOUNTED_DR ent_dr,
    jl.ACCOUNTED_CR ent_cr,
    jh.external_reference reference,
    jl.reference_2 ref2,
    jl.reference_3 ref3,
    nvl(jl.period_name,0) per_name,
    nvl(ir.reference_1,' ') reference_1,
    ir.reference_2 reference_2,
    ir.reference_3 reference_3,
    ir.reference_4 transaction_no,
    nvl(ir.reference_5,' ') reference_5,
    ir.reference_6 reference_6,
    ir.reference_7 reference_7,
    ir.reference_8 reference_8,
    ir.reference_9 reference_9,
    ir.reference_10 reference_10,
    ir.subledger_doc_sequence_id seq_id,
    ir.subledger_doc_sequence_value seq_num,
    jh.doc_sequence_id h_seq_id,
    nvl(ir.gl_sl_link_id,0) gl_sl_link_id,
    null ae_line_id,
    jl.code_combination_id gl_code_id,
    hou.ORGANIZATION_ID org_id,
    hou.name org_name
    from GL_JE_LINES jl,
    GL_JE_HEADERS jh,
    GL_JE_BATCHES jb,
    GL_JE_SOURCES js,
    GL_JE_CATEGORIES jc,
    GL_IMPORT_REFERENCES ir,
    --ap_ae_lines_all            ael,
    FND_DOCUMENT_SEQUENCES ds,
    gl_code_combinations gcc,
    fnd_flex_values_vl ffv,
    hr_operating_units hou
    where
    jl.status||'' = 'P'
    --- and jl.code_combination_id = :ccid
    ---and jl.set_of_books_id = :P_SET_OF_BKS_ID
    and jh.status = 'P'
    and jh.actual_flag = 'A'
    and jh.je_header_id = jl.je_header_id + 0
    ---jh.je_source||'' like
    --decode(:P_SOURCE,'','%', :P_SOURCE)
    -- and jh.je_category||'' like decode(:P_CATEGORY,'','%',:P_CATEGORY)
    and jb.je_batch_id = jh.je_batch_id + 0
    and jb.average_journal_flag = 'N'
    and js.je_source_name = jh.je_source
    and jc.je_category_name = jh.je_category
    and ir.je_header_id (+) = jl.je_header_id
    and ir.je_line_num (+) = jl.je_line_num
    and ( ir.rowid IS NULL
    --or jh.je_source                   IN  ('Inventory','Payables', 'Receivables','Purchasing')
    or ir.rowid IN ( SELECT max(ir2.rowid)
    FROM gl_import_references ir2
    WHERE ir2.je_header_id = jl.je_header_id
    AND ir2.je_line_num = jl.je_line_num))
    --and ael.gl_sl_link_id(+)       =  ir.gl_sl_link_id
    and ds.doc_sequence_id (+) = ir.subledger_doc_sequence_id
    and gcc.CODE_COMBINATION_ID = jl.CODE_COMBINATION_ID
    and ffv.FLEX_VALUE_SET_ID='1009979'
    and gcc.SEGMENT4=ffv.FLEX_VALUE
    and gcc.SEGMENT1 =:location -11
    and gcc.SEGMENT4 between nvl(:From_acc,gcc.SEGMENT4) and nvl(:To_acc,gcc.SEGMENT4)
    --AND GCC.SEGMENT2 =NVL(:DIV,GCC.SEGMENT2)
    and gcc.segment2 BETWEEN nvl(:FROM_Div,gcc.segment2) AND NVL(:TO_DIV,GCC.SEGMENT2)
    and jl.effective_date between nvl(:from_date,jl.effective_date) and nvl(:to_date,jl.effective_date)
    and gcc.SEGMENT1 between nvl(:from_loc,gcc.SEGMENT1) and nvl(:to_loc,gcc.SEGMENT1)
    and hou.ORGANIZATION_ID=:Operating_Unit
    AND JH.JE_SOURCE <>'Purchase Invoices'
    AND nvl(JL.GL_SL_LINK_ID,0) <> 85508
    --order by jl.EFFECTIVE_DATE,gcc.SEGMENT4
    UNION ALL
    select distinct
    null NAME,
    null JHI ,
    gcc.SEGMENT4 account_num,
    ffv.description DESCRIPTION,
    xai.user_je_category_name category,
    xai.doc_sequence_value seq_num1,
    xai.doc_sequence_name lseq,
    null cat_name,
    gcc.segment1 location,
    gcc.segment2 division,
    null acc_desc,
    null source,
    null je_header_id,
    null je_line_num,
    xai.accounting_date Accounted_Date,
    null entry,
    null batch,
    xai.comments naration,
    null LSequence,
    null Document_num,
    null LLine,
    xai.accounted_dr debit,
    xai.accounted_cr credit,
    xai.accounted_dr ent_dr,
    xai.accounted_cr ent_cr,
    null reference,
    null ref2,
    null ref3,
    null per_name,
    xai.third_party_name reference_1,
    null reference_2,
    null reference_3,
    null transaction_no,
    null reference_5,
    null reference_6,
    null reference_7,
    null reference_8,
    null reference_9,
    null reference_10,
    null seq_id,
    null seq_num,
    null h_seq_id,
    null gl_sl_link_id,
    null ae_line_id,
    null gl_code_id,
    hou.ORGANIZATION_ID org_id,
    hou.name org_name
    from GL_JE_LINES jl,
    GL_JE_HEADERS jh,
    GL_JE_BATCHES jb,
    GL_JE_SOURCES js,
    GL_JE_CATEGORIES jc,
    GL_IMPORT_REFERENCES ir,
    --ap_ae_lines_all            ael,
    FND_DOCUMENT_SEQUENCES ds,
    gl_code_combinations gcc,
    fnd_flex_values_vl ffv,
    hr_operating_units hou,
    xla_ap_inv_ael_gl_v xai
    where
    jl.status||'' = 'P'
    --- and jl.code_combination_id = :ccid
    ---and jl.set_of_books_id = :P_SET_OF_BKS_ID
    and jh.status = 'P'
    and jh.actual_flag = 'A'
    and jh.je_header_id = jl.je_header_id + 0
    ---jh.je_source||'' like
    --decode(:P_SOURCE,'','%', :P_SOURCE)
    -- and jh.je_category||'' like decode(:P_CATEGORY,'','%',:P_CATEGORY)
    and jb.je_batch_id = jh.je_batch_id + 0
    and jb.average_journal_flag = 'N'
    and js.je_source_name = jh.je_source
    and jc.je_category_name = jh.je_category
    and ir.je_header_id (+) = jl.je_header_id
    and ir.je_line_num (+) = jl.je_line_num
    and ( ir.rowid IS NULL
    --or jh.je_source                   IN  ('Inventory','Payables', 'Receivables','Purchasing')
    or ir.rowid IN ( SELECT max(ir2.rowid)
    FROM gl_import_references ir2
    WHERE ir2.je_header_id = jl.je_header_id
    AND ir2.je_line_num = jl.je_line_num))
    --and ael.gl_sl_link_id(+)       =  ir.gl_sl_link_id
    and ds.doc_sequence_id (+) = ir.subledger_doc_sequence_id
    and gcc.CODE_COMBINATION_ID = jl.CODE_COMBINATION_ID
    and ffv.FLEX_VALUE_SET_ID='1009979'
    and gcc.SEGMENT4=ffv.FLEX_VALUE
    and gcc.SEGMENT1 =:location -11
    and gcc.SEGMENT4 between nvl(:From_acc,gcc.SEGMENT4) and nvl(:To_acc,gcc.SEGMENT4)
    --AND GCC.SEGMENT2 =NVL(:DIV,GCC.SEGMENT2)
    and gcc.segment2 BETWEEN nvl(:FROM_Div,gcc.segment2) AND NVL(:TO_DIV,GCC.SEGMENT2)
    and jl.effective_date between nvl(:from_date,jl.effective_date) and nvl(:to_date,jl.effective_date)
    and gcc.SEGMENT1 between nvl(:from_loc,gcc.SEGMENT1) and nvl(:to_loc,gcc.SEGMENT1)
    and hou.ORGANIZATION_ID=:Operating_Unit
    AND JH.JE_SOURCE <>'Purchase Invoices'
    AND JL.GL_SL_LINK_ID ='85508'
    and xai.application_id = 200
    AND xai.je_header_id = 4268
    AND xai.je_line_num = 3
    union
    select
    jh.NAME,JH.
    JE_HEADER_ID ,
    nvl(gcc.SEGMENT4,0) account_num,
    nvl(ffv.DESCRIPTION,0) DESCRIPTION,
    decode(jc.je_category_name,'7','JV','8','JV','9','JV',jc.je_category_name)category,
    null seq_num1,
    null lseq,
    jc.USER_JE_CATEGORY_NAME cat_name,
    nvl(gcc.SEGMENT1 ,0) location,
    nvl(gcc.SEGMENT2,0) division,
    ffv.DESCRIPTION acc_desc,
    jh.je_source source,
    ir.je_header_id je_header_id,
    ir.je_line_num je_line_num,
    jl.effective_date Accounted_Date,
    jh.name entry,
    jh.je_batch_id batch,
    substr(AID.DESCRIPTION,1,250) naration,
    ds.name LSequence,
    jh.doc_sequence_value Document_num,
    jl.je_line_num LLine,
    nvl(jl.accounted_dr,0) debit,
    nvl(jl.accounted_cr ,0) credit,
    jl.ACCOUNTED_DR ent_dr,
    jl.ACCOUNTED_CR ent_cr,
    jh.external_reference reference,
    jl.reference_2 ref2,
    jl.reference_3 ref3,
    nvl(jl.period_name,0) per_name,
    nvl(ir.reference_1,' ') reference_1,
    ir.reference_2 reference_2,
    ir.reference_3 reference_3,
    ir.reference_4 transaction_no,
    nvl(ir.reference_5,' ') reference_5,
    ir.reference_6 reference_6,
    ir.reference_7 reference_7,
    ir.reference_8 reference_8,
    ir.reference_9 reference_9,
    ir.reference_10 reference_10,
    ir.subledger_doc_sequence_id seq_id,
    ir.subledger_doc_sequence_value seq_num,
    jh.doc_sequence_id h_seq_id,
    ir.gl_sl_link_id gl_sl_link_id,
    ael.ae_line_id ae_line_id,
    jl.code_combination_id gl_code_id,
    hou.ORGANIZATION_ID org_id,
    hou.name org_name
    from GL_JE_LINES jl,
    GL_JE_HEADERS jh,
    GL_JE_BATCHES jb,
    GL_JE_SOURCES js,
    GL_JE_CATEGORIES jc,
    GL_IMPORT_REFERENCES ir,
    ap_ae_lines_all ael,
    FND_DOCUMENT_SEQUENCES ds,
    gl_code_combinations gcc,
    fnd_flex_values_vl ffv,
    hr_operating_units hou,
    AP_INVOICEs_ALL AID
    where
    jl.status||'' = 'P'
    --- and jl.code_combination_id = :ccid
    ---and jl.set_of_books_id = :P_SET_OF_BKS_ID
    and jh.status = 'P'
    and jh.actual_flag = 'A'
    and jh.je_header_id = jl.je_header_id + 0
    ---jh.je_source||'' like
    --decode(:P_SOURCE,'','%', :P_SOURCE)
    -- and jh.je_category||'' like decode(:P_CATEGORY,'','%',:P_CATEGORY)
    and jb.je_batch_id = jh.je_batch_id + 0
    and jb.average_journal_flag = 'N'
    and js.je_source_name = jh.je_source
    and jc.je_category_name = jh.je_category
    and ir.je_header_id (+) = jl.je_header_id
    and ir.je_line_num (+) = jl.je_line_num
    and ( ir.rowid IS NULL
    --or jh.je_source                   IN  ('Inventory','Payables', 'Receivables','Purchasing')
    or ir.rowid IN ( SELECT max(ir2.rowid)
    FROM gl_import_references ir2
    WHERE ir2.je_header_id = jl.je_header_id
    AND ir2.je_line_num = jl.je_line_num))
    and ael.gl_sl_link_id(+) = ir.gl_sl_link_id
    and ds.doc_sequence_id (+) = ir.subledger_doc_sequence_id
    and gcc.CODE_COMBINATION_ID = jl.CODE_COMBINATION_ID
    and ffv.FLEX_VALUE_SET_ID='1009979'
    and gcc.SEGMENT4=ffv.FLEX_VALUE
    and gcc.SEGMENT1 =:location -11
    and gcc.SEGMENT4 between nvl(:From_acc,gcc.SEGMENT4) and nvl(:To_acc,gcc.SEGMENT4)
    --AND GCC.SEGMENT2 =NVL(:DIV,GCC.SEGMENT2)
    and gcc.segment2 BETWEEN nvl(:FROM_Div,gcc.segment2) AND NVL(:TO_DIV,GCC.SEGMENT2)
    and jl.effective_date between nvl(:from_date,jl.effective_date) and nvl(:to_date,jl.effective_date)
    and gcc.SEGMENT1 between nvl(:from_loc,gcc.SEGMENT1) and nvl(:to_loc,gcc.SEGMENT1)
    and hou.ORGANIZATION_ID=:Operating_Unit
    AND JH.JE_SOURCE LIKE 'Purchase Invoices'
    AND IR.REFERENCE_2 = AID.INVOICE_ID
    union all
    select
    distinct
    null NAME,
    null JHI ,
    nvl(gcc.SEGMENT4,0) account_num,
    nvl(ffv.DESCRIPTION,0) DESCRIPTION,
    null category,
    null seq_num1,
    null lseq,
    null cat_name,
    nvl(gcc.SEGMENT1 ,0) location,
    nvl(gcc.SEGMENT2,0) division ,
    null acc_desc,
    null source,
    null je_header_id,
    null je_line_num,
    null Accounted_Date,
    null entry,
    null batch,
    null naration,
    null LSequence,
    null Document_num,
    null LLine,
    null debit,
    null credit,
    null ent_dr,
    null ent_cr,
    null reference,
    null ref2,
    null ref3,
    null per_name,
    null reference_1,
    null reference_2,
    null reference_3,
    null transaction_no,
    null reference_5,
    null reference_6,
    null reference_7,
    null reference_8,
    null reference_9,
    null reference_10,
    null seq_id,
    null seq_num,
    null h_seq_id,
    null gl_sl_link_id,
    null ae_line_id,
    null gl_code_id,
    null org_id,
    null org_name
    from gl_code_combinations gcc ,fnd_flex_values_vl ffv
    where gcc.SEGMENT4 between nvl(:From_acc,gcc.SEGMENT4) and nvl(:To_acc,gcc.SEGMENT4)
    and gcc.segment2 BETWEEN nvl(:FROM_Div,gcc.segment2) AND NVL(:TO_DIV,GCC.SEGMENT2)
    and gcc.SEGMENT1 between nvl(:from_loc,gcc.SEGMENT1) and nvl(:to_loc,gcc.SEGMENT1)
    and ffv.FLEX_VALUE_SET_ID='1009979'
    and gcc.SEGMENT4=ffv.FLEX_VALUE
    and gcc.CODE_COMBINATION_ID not in (
    select distinct
    jl.code_combination_id gl_code_id
    from GL_JE_LINES jl,
    GL_JE_HEADERS jh,
    GL_JE_BATCHES jb,
    GL_JE_SOURCES js,
    GL_JE_CATEGORIES jc,
    GL_IMPORT_REFERENCES ir,
    ap_ae_lines_all ael,
    FND_DOCUMENT_SEQUENCES ds,
    gl_code_combinations gcc,
    fnd_flex_values_vl ffv,
    hr_operating_units hou
    where
    jl.status||'' = 'P'
    --- and jl.code_combination_id = :ccid
    ---and jl.set_of_books_id = :P_SET_OF_BKS_ID
    and jh.status = 'P'
    and jh.actual_flag = 'A'
    and jh.je_header_id = jl.je_header_id + 0
    ---jh.je_source||'' like
    --decode(:P_SOURCE,'','%', :P_SOURCE)
    -- and jh.je_category||'' like decode(:P_CATEGORY,'','%',:P_CATEGORY)
    and jb.je_batch_id = jh.je_batch_id + 0
    and jb.average_journal_flag = 'N'
    and js.je_source_name = jh.je_source
    and jc.je_category_name = jh.je_category
    and ir.je_header_id (+) = jl.je_header_id
    and ir.je_line_num (+) = jl.je_line_num
    and ( ir.rowid IS NULL
    --or jh.je_source                   IN  ('Inventory','Payables', 'Receivables','Purchasing')
    or ir.rowid IN ( SELECT max(ir2.rowid)
    FROM gl_import_references ir2
    WHERE ir2.je_header_id = jl.je_header_id
    AND ir2.je_line_num = jl.je_line_num))
    and ael.gl_sl_link_id(+) = ir.gl_sl_link_id
    and ds.doc_sequence_id (+) = ir.subledger_doc_sequence_id
    and gcc.CODE_COMBINATION_ID = jl.CODE_COMBINATION_ID(+)
    and ffv.FLEX_VALUE_SET_ID='1009979'
    and gcc.SEGMENT4=ffv.FLEX_VALUE(+)
    and gcc.SEGMENT1 =:location -11
    and gcc.SEGMENT4 between nvl(:From_acc,gcc.SEGMENT4) and nvl(:To_acc,gcc.SEGMENT4)
    --AND GCC.SEGMENT2 =NVL(:DIV,GCC.SEGMENT2)
    and gcc.segment2 BETWEEN nvl(:FROM_Div,gcc.segment2) AND NVL(:TO_DIV,GCC.SEGMENT2)
    and jl.effective_date between nvl(:from_date,jl.effective_date) and nvl(:to_date,jl.effective_date)
    and gcc.SEGMENT1 between nvl(:from_loc,gcc.SEGMENT1) and nvl(:to_loc,gcc.SEGMENT1)
    and hou.ORGANIZATION_ID=:Operating_Unit
    AND JH.JE_SOURCE <>'Purchase Invoices' ))A
    order by A.Accounted_Date,A.account_num,A.seq_NUM
    can any body give the steps how to implement its business area and work book i(step by step) ?
    **i am using discoverer 10g**
    Thanks & Regards,
    azamtulla khan

    In its simplest form - you want to create a custom folder (Insert -> Folder -> Custom) in Disco Admin using the SQL from the report.
    You cannot have bind parameters in your SQL, so you will have to use a trick detailed in Note 304192.1 on metalink.
    This allows you to restrict your query within the SQL of the custom folder.
    If you don't do it this way you could hit performance issues as any parameters defined in the workbook will be applied after the SQL in the custom folder has been run.
    Hope this gets you on the way.

  • Insert porb

    Hi Experts,
    I am getting one error when inseting data into table.i am pasting my code
    here.please give me the solution.
    [pre]
    INSERT INTO   ARC.ARC_CUSTOMER_STAT_REPORT_1
    (SELECT A.customer customer,
                         A.customer_number customer_number,
                     A.customer_id customer_id,
                     A.transaction_number transaction_number,
                     A.transaction_date transaction_date,
                         A.due_date due_date,
                         A.CLASS classes,
                         A.invoice_currency_code invoice_currency_code,
                         A.exchange_rate exchange_rate,
                         A.amount_due_remaining amount_due_remaining,
                         A.invoices_inv invoices_inv,
                         A.debit_memo debit_memo,
                         A.out_standing_amt out_standing_amt,
                         A.unapplied_credits unapplied_credits,
                     A.UNAPPLIED_RECEIPTS UNAPPLIED_RECEIPTS,
                         A.TYPE TYPE,
                         A.STATUS STATUS,
                         A.BATCH_NAME BATCH_NAME,
                     A.TRX_REFERENCE TRX_REFERENCE,
                         A.AMT_TYPE AMT_TYPE,
                         A.DAYS_LATE DAYS_LATE,
                     A.customer_trx_type_id customer_trx_type_id,
                         A.RECEIPT_NUMBER RECEIPT_NUMBER,
                     A.customer_trx_line_id customer_trx_line_id,
                         A.org_id org_id,
                         A.receipt_date receipt_date,
                     A.attribute1 attribute1,
                         A.amount_applied
                FROM (SELECT ra.customer_name customer,
                             ra.customer_number customer_number,
                             ra.customer_id customer_id,                              
                             ap.trx_number transaction_number,
                             ap.trx_date transaction_date,
                                   ap.due_date due_date,
                                   ap.CLASS CLASS,
                             ap.invoice_currency_code invoice_currency_code,
                                   ap.exchange_rate exchange_rate,
                             ap.amount_due_remaining amount_due_remaining,
                             NVL((DECODE (ap.CLASS,'INV',ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) invoices_inv,
                             NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) debit_memo,
                             NVL((DECODE (ap.CLASS,'INV', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) +
                                          NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) out_standing_amt,
                             NVL((DECODE (ap.CLASS,'CM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1) )),0) unapplied_credits,
                                   NVL(DECODE(AP.CLASS,'PMT',ROUND(AP.AMOUNT_DUE_REMAINING * NVL(AP.EXCHANGE_RATE,1),2)),0) UNAPPLIED_RECEIPTS,
                             ratt.TYPE TYPE,
                                   ap.STATUS STATUS,
                                   rbs.name BATCH_NAME,
                                   rat.ct_reference TRX_REFERENCE,
                                   'OPEN_BAL' AMT_TYPE,
                                   MAX(TO_DATE(AP.DUE_DATE,'DD-MON-RRRR') - TO_DATE(RAT.TRX_DATE,'DD-MON-RRRR')) DAYS_LATE,
                                   rat.cust_trx_type_id customer_trx_type_id,TO_CHAR(0) RECEIPT_NUMBER,ratl.customer_trx_line_id customer_trx_line_id,
                             ap.org_id org_id,NULL receipt_date, NULL attribute1,
                             0 amount_applied
                        FROM ar_payment_schedules_all ap,
                             apps.ra_customer_trx_all rat,
                             apps.ra_cust_trx_types_all ratt,
                             hz_cust_site_uses_all hzc,
                             hz_cust_acct_sites_all hzca,
                             ra_customers ra,
                             ra_cust_trx_line_gl_dist_all rag,
                             ra_customer_trx_lines_all ratl,
                                   RA_BATCH_SOURCES_ALL RBS
                       WHERE ap.status = 'OP'
                         AND ap.amount_due_remaining <> 0
                         AND ratl.line_type = 'LINE'
                         AND ap.customer_site_use_id = hzc.site_use_id
                              AND rat.batch_source_id = rbs.batch_source_id
                         AND ra.customer_id = ap.customer_id
                         AND rat.cust_trx_type_id = ratt.cust_trx_type_id
                         AND ap.customer_trx_id = rat.customer_trx_id
                         AND rag.customer_trx_id = ap.customer_trx_id
                         AND ap.customer_trx_id = ratl.customer_trx_id
                         AND rag.customer_trx_line_id = ratl.customer_trx_line_id
                         AND hzc.cust_acct_site_id = hzca.cust_acct_site_id
                         AND TRUNC (ap.trx_date) <= '02-sep-2007'
                         AND ap.org_id = :P_org_id
                         GROUP BY ra.customer_name ,
                             ra.customer_number ,
                             ra.customer_id ,                              
                             ap.trx_number ,
                             ap.trx_date ,
                                   ap.due_date ,
                                   ap.CLASS ,
                             ap.invoice_currency_code ,
                                   ap.exchange_rate ,
                             ap.amount_due_remaining,
                                   ap.exchange_rate,
                             ratt.TYPE ,
                                   ap.STATUS ,
                                   rbs.name ,
                                   rat.ct_reference ,
                                   rat.cust_trx_type_id ,
                                   ratl.customer_trx_line_id ,
                             ap.org_id          
                      UNION ALL
                      SELECT ra.customer_name customer,
                             ra.customer_number customer_number,
                             ra.customer_id customer_id,                              
                             ap.trx_number transaction_number,
                             ap.trx_date transaction_date,
                                   ap.due_date due_date,
                             ap.CLASS clas,
                             ap.invoice_currency_code invoice_currency_code,
                             ap.exchange_rate exchange_rate,
                             ap.amount_due_remaining amount_due_remaining,
                             NVL((DECODE (ap.CLASS,'INV',ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) invoices_inv,
                             NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) debit_memo,
                             NVL((DECODE (ap.CLASS,'INV', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) +
                                          NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) out_standing_amt,
                             NVL((DECODE (ap.CLASS,'CM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1) )),0) unapplied_credits,
                                   NVL(DECODE(AP.CLASS,'PMT',ROUND(AP.AMOUNT_DUE_REMAINING * NVL(AP.EXCHANGE_RATE,1),2)),0) UNAPPLIED_RECEIPTS,
                             ratt.TYPE TYPE,
                                   ap.STATUS STATUS,
                                   rbs.name BATCH_NAME,
                                   rat.ct_reference TRX_REFERENCE,
                                   'OPEN_BAL' AMT_TYPE,
                                  MAX(TO_DATE(AP.DUE_DATE,'DD-MON-RRRR') - TO_DATE(RAT.TRX_DATE,'DD-MON-RRRR')) DAYS_LATE,
                                   rat.cust_trx_type_id customer_trx_type_id,
                                   TO_CHAR(0) RECEIPT_NUMBER,
                             ratl.customer_trx_line_id customer_trx_line_id,
                             ap.org_id org_id,
                             NULL receipt_date, 
                                   NULL attribute1,
                             0 amount_applied
                        FROM apps.ra_customer_trx_all rat,
                             ar_payment_schedules_all ap,
                             ra_customers ra,
                             apps.ra_cust_trx_types_all ratt,
                                   ra_customer_trx_lines_all ratl,
                                   RA_BATCH_SOURCES_ALL RBS
                       WHERE ap.status = 'OP'
                              AND rat.batch_source_id = rbs.batch_source_id                      
                         AND ap.amount_due_remaining <> 0
                         AND ap.customer_trx_id = rat.customer_trx_id
                               AND rat.batch_source_id = rbs.batch_source_id
                         AND rat.cust_trx_type_id = ratt.cust_trx_type_id
                          AND ap.customer_trx_id = ratl.customer_trx_id
                         AND ra.customer_id = ap.customer_id
                         AND ap.trx_date > '02-sep-2007'
                         AND ap.org_id = :P_org_id
                        GROUP BY
                                  ra.customer_name ,
                             ra.customer_number ,
                             ra.customer_id ,                              
                             ap.trx_number ,
                             ap.trx_date ,
                                   ap.due_date ,
                             ap.CLASS ,
                             ap.invoice_currency_code ,
                             ap.exchange_rate ,
                                    ratt.TYPE,
                             ap.amount_due_remaining ,
                             ap.amount_due_remaining,
                                   ap.exchange_rate,
                                   ap.STATUS ,
                                   RBS.NAME ,
                                   rat.ct_reference ,
                                   rat.cust_trx_type_id ,
                                   ratl.customer_trx_line_id,
                             ap.org_id     
                      UNION ALL
                      SELECT ra.customer_name customer,
                             ra.customer_number customer_number,
                             ra.customer_id customer_id,                              
                             ap.trx_number transaction_number,
                             ap.trx_date transaction_date,
                                   ap.due_date due_date,
                             ap.CLASS clas,
                             ap.invoice_currency_code invoice_currency_code,
                             ap.exchange_rate exchange_rate,
                             ap.amount_due_remaining amount_due_remaining,
                             NVL((DECODE (ap.CLASS,'INV',ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) invoices_inv,
                             NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) debit_memo,
                             NVL((DECODE (ap.CLASS,'INV', ap.amount_due_remaining* NVL (ap.exchange_rate, 1))),0) +
                                          NVL ((DECODE (ap.CLASS,'DM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1))),0) out_standing_amt,
                             NVL((DECODE (ap.CLASS,'CM', ap.amount_due_remaining * NVL (ap.exchange_rate, 1) )),0) unapplied_credits,
                                   NVL(DECODE(AP.CLASS,'PMT',ROUND(AP.AMOUNT_DUE_REMAINING * NVL(AP.EXCHANGE_RATE,1),2)),0) UNAPPLIED_RECEIPTS,
                             TO_CHAR(0) TYPE,
                                   ap.STATUS STATUS,
                                   TO_CHAR(0) BATCH_NAME,
                                   TO_CHAR(0) TRX_REFERENCE,
                                   'OPEN_BAL' AMT_TYPE,
                                   0 DAYS_LATE,
                                   0 customer_trx_type_id,
                                   CR.RECEIPT_NUMBER RECEIPT_NUMBER,
                             0 customer_trx_line_id,
                             ap.org_id org_id,
                             NULL receipt_date, 
                                   NULL attribute1,
                             ARA.amount_applied AMOUNT_APPLIED
                        FROM ar_cash_receipts_all cr,
                             ar_receivable_applications_all ara,
                             ar_payment_schedules_all ap,
                             ra_customers ra,
                             hz_cust_site_uses_all hzc,
                             hz_cust_acct_sites_all hzca   
                      WHERE  ap.status = 'OP'
                         AND ara.status = 'UNAPP'
                         AND ap.customer_site_use_id = hzc.site_use_id
                         AND ra.customer_id = ap.customer_id
                         AND ap.payment_schedule_id = ara.payment_schedule_id
                         AND cr.cash_receipt_id = ap.cash_receipt_id
                         AND hzc.cust_acct_site_id = hzca.cust_acct_site_id
                         AND ap.org_id = :P_org_id
                               GROUP BY ra.customer_name ,
                             ra.customer_number ,
                             ra.customer_id ,                              
                             ap.trx_number ,
                             ap.trx_date ,
                                   ap.due_date ,
                             ap.CLASS ,
                             ap.invoice_currency_code ,
                             ap.exchange_rate ,
                             ap.amount_due_remaining ,
                             ap.STATUS ,
                                   CR.RECEIPT_NUMBER ,
                             ap.org_id ,
                             ARA.amount_applied ) A)
    [/pre]I am Getting Error Like Invalid Number

    1) Specifying the Oracle error number in addition to the error message is generally helpful because we can more easily look up error numbers.
    2) I'll wager that the problem is that somewhere in this statement, Oracle is implicitly casting a VARCHAR2 column to a number in order to do a comparison and that conversion is failing on one or more rows. The fixes for that sort of thing are, in order
    - Fix your data model so that you don't store numeric data in varchar2 columns
    - Fix your data model so that columns that are compared with each other have the same data type
    - Ensure that literals and bind variables are of the same type as the columns they're being compared against.
    - If you need to compare a string to a number, do the conversion explicitly (i.e. using TO_NUMBER or TO_CHAR) and ensure that every row of the source can actually be converted to the destination data type
    3) Putting TO_DATE calls on columns whose names indicate they are dates to begin with is a bad idea. That forces Oracle to do an implicit conversion of the date to a string using the session's NLS_DATE_FORMAT, then converts it back to a date, which is extra work and extra opportunities for error with no benefit.
    4) Comparing date columns to string literals is a similarly bad idea. You would want to put an explicit TO_DATE around the string literal if you are really comparing the result to a date column.
    Justin

  • Did not get org id in parameter form

    HI,
    select * from HR_OPERATING_UNITS
    organization_id IN (SELECT organization_id
    FROM hr_operating_units hou1
    WHERE default_legal_context_id IN (SELECT default_legal_context_id
    FROM hr_operating_units hou2
    WHERE hou2.organization_id = FND_PROFILE.VALUE_SPECIFIC(NAME => 'ORG_ID',
    USER_ID => fnd_profile.value('USER_ID'),
    RESPONSIBILITY_ID => fnd_profile.value('RESP_ID'),
    APPLICATION_ID => fnd_profile.value('RESP_APPL_ID'),
    ORG_ID => null,
    SERVER_ID => null)))
    please find created value set Xxxx_OPERATING_UNITS and written the above code after we have attached the value set to the parameter window. we ran the request submission i not able to find the list of values i am getting only no list of values found.
    please i am not figured out where the problem lies..........it is great help ful to me .........
    we will change any profile or?????????????
    user.
    Edited by: user13100220 on Apr 3, 2013 4:40 PM

    Have you tried running the query in a SqlPlus session? The query you are providing doesn't seem to be correct. At least, you are missing a "WHERE" after the first HR_OPERATING_UNITS.

  • Using Highlight for columns in data tables

    Hi, I'm using the "Highlight" function of SpryEffects in
    combination with the sorting features. My HTML structure is a
    simple data table, with a repeating region on the table row, so it
    pulls in as many rows there are pieces in the attached XML file.
    When I sort by one of the column headers at the top, I want to
    highlight that whole column, so users can see what they're sorting
    by. I'm able to get the first row of the data table highlighted,
    but none of the following rows work. I'm pretty sure the problem is
    that the highlight function only works when you use an id to define
    the element that you want highlighted. If it's in a repeating row,
    it sees many ids on the page, and only applies the highlight to the
    first one. I want to change the id to a class, so I can put
    multiple ones on the page and have it work, but I can't see how to
    do that in the SpryEffects.js file.
    Can anyone tell me if it's possible to do this? Thanks.
    Here's the portion of the .js file:
    function setupHighlight(element, effect)
    Spry.Effect.setStyleProp(element, 'background-image',
    'none');
    function finishHighlight(element, effect)
    Spry.Effect.setStyleProp(element, 'background-image',
    effect.options.restoreBackgroundImage);
    if (effect.direction == Spry.forwards)
    Spry.Effect.setStyleProp(element, 'background-color',
    effect.options.restoreColor);
    Spry.Effect.Highlight = function (element, options)
    var durationInMilliseconds = 1000;
    var toColor = "#ffffff";
    var doToggle = false;
    var kindOfTransition = Spry.sinusoidalTransition;
    var setupCallback = setupHighlight;
    var finishCallback = finishHighlight;
    var element = Spry.Effect.getElement(element);
    var fromColor = Spry.Effect.getStyleProp(element,
    "background-color");
    var restoreColor = fromColor;
    if (fromColor == "transparent") fromColor = "#ffff99";
    var optionFrom = options ? options.from : '#ffff00';
    var optionTo = options ? options.to : '#0000ff';
    if (options)
    if (options.duration != null) durationInMilliseconds =
    options.duration;
    if (options.from != null) fromColor = options.from;
    if (options.to != null) toColor = options.to;
    if (options.restoreColor) restoreColor =
    options.restoreColor;
    if (options.toggle != null) doToggle = options.toggle;
    if (options.transition != null) kindOfTransition =
    options.transition;
    if (options.setup != null) setupCallback = options.setup;
    if (options.finish != null) finishCallback = options.finish;
    var restoreBackgroundImage =
    Spry.Effect.getStyleProp(element, 'background-image');
    options = {duration: durationInMilliseconds, toggle:
    doToggle, transition: kindOfTransition, setup: setupCallback,
    finish: finishCallback, restoreColor: restoreColor,
    restoreBackgroundImage: restoreBackgroundImage, from: optionFrom,
    to: optionTo};
    var highlightEffect = new Spry.Effect.Color(element,
    fromColor, toColor, options);
    highlightEffect.name = 'Highlight';
    var registeredEffect =
    SpryRegistry.getRegisteredEffect(element, highlightEffect);
    registeredEffect.start();
    return registeredEffect;

    Hi Philip, Thanks a lot for puting this enhancement request through.
    Just downloaded the latest Patch upgrading to v 3.1.2-704 and confirmed that this functionality is not available yet.
    Keeping your experience in mind what kind of expectation to you have for the approval and realization of your request?
    Most likely this will take a couple of month – right? Or is there a beta version of 3.2 already available we could use.
    Thanks a lot. Cheers Stefan

  • R12.1.1 Receivable Module Implementation Issue

    Hi Friends
    I have going to implement R12.1.1 receivable module. I have already implemented same version GL module.
    Now I am working R12.1.1 vision server to initial implement of AR module but I am getting an error and I can’t open any transaction screen. I have done below works:
    1.     Create a Receivable Responsibility (IBCS Receivable Administrator)
    2.     The above (IBCS Receivable Administrator) responsibility I have created from Receivable Vision Operation (USA) i.e. Menu, Request Set etc.
    3.     I have created a Legal Entry and Operating Unit
    4.     Assigned the Operating Unit with IBCS Receivable Administrator
    5.     Assigned the above responsibility with my user
    After doing the above 5 activities when I am trying to open any receivable transaction I getting below error:
    ORA-01403: no data found
    FRM-40735: PRE-FORM trigger raised unhandled exception ORA-06502.
    Please help me. I will be very happy if anybody give a quick solution.
    Thanks
    Makshud

    Hi ;
    Please check below and see its helpful:
    ARXSUDRC: Cannot Open Receipt Class Form - FRM-40735, ORA-6502 [ID 729552.1]
    Quoting Forms User Interface TSG (11.5.6 - 11.5.8) [ID 181041.1] <<part : Error: FRM-40735, ORA-06508, ORA-01403: Setup Sales Supplement Data form errors Problem
    MultiOrg Setup: FRM-40735 Trigger raised unhandled exception in Form ARXTWMAI and ARXRWMAI [ID 260244.1]
    Regard
    Helios

Maybe you are looking for

  • Is hotmail down again?

    I noticed yesterday evening that I hadn't received any e-mails to my hotmail account since about 14:00 GMT but Yahoo, Ovi and Sky are still working and sending / receiving e-mails as expected. I've checked my hotmail account using the web and Windows

  • Help Menu is Wrong - Menu button on remote needs to go...

    to Menu. Seems like a no-brainer. Help menu says: "The remote control settings are in different Inspector locations for different elements: Disc Inspector: The commonly used remote control settings (Title, Menu, and Return) are in the General tab. Th

  • TS3988 my information wont sync with icloud

    I keep trying to back up my IPhone 5 to ICloud with no luck, I've tried just about everything except calling the support line, any idea's?

  • Iphoto does not work properly after accidental power disconnect

    I was working in iPhoto with a flash drive when the power cord became unplugged. When I plugged the cord back in, all the photos in my library vanished. I can still import from a camera/flash drive/disk but I can't put the photos in My Pictures file

  • I can't seem to login to my account

    Hello everyone! So somehow my post didn't get posted and i'll shorten things up. Since yesterday I can't seem to login to my account anymore, I get the message my data isn't correct. So i tried to change the password and nothing happened, still could