Oracle E-Business suite custom application development-How to submit a concurrent request from a FORM module through push button click

 

Required: FNDCONC.pll attached to custom form

with when-button-pressed trigger, attach the following code (Please remove what is not applicable in your case)

Declare
  l_ord_num               NUMBER := 0;
   l_ord_type_name         VARCHAR2 (240);
   l_req_id_Rep            NUMBER;
   l_request_completed     BOOLEAN := FALSE;
   l_req_phase             VARCHAR2 (20);
   l_req_status            VARCHAR2 (1000);
   l_req_dev_phase         VARCHAR2 (1000);
   l_req_dev_status        VARCHAR2 (1000);
   l_req_message           VARCHAR2 (1000);
   l_conc_mgr_status       NUMBER;
   p_call_stat             NUMBER;
   p_activep_stat          NUMBER;

   l_order_category_code   NUMBER;
   l_inv_report_name       VARCHAR2 (40);
   l_ret_report_name       VARCHAR2 (40);
   l_req_id                                 NUMBER;
   l_order_type_name                VARCHAR2(30);
Begin
  l_req_id :=
      fnd_request.submit_request (‘ONT’,—Actual application short name
                                  l_inv_report_name,—Short name of concurrent program, please note this is not the executable name
                                  NULL,—Description not required
                                  SYSDATE,—start time, not required
                                  FALSE,—subsequent report name, not required

/*You can pass a total of 100 parameters, just make sure to pass them in the same order you have defined them in the parameter session for the concurrent program*/
                                  :ORDERS.OE_ORDER_NUMBER,                                   l_order_type_name,                                   NULL,
                                  NULL,
                                  apps.fnd_profile.VALUE (‘ORG_ID’));

:SYSTEM.Message_Level := ’25’;
   COMMIT;

   l_request_completed :=
      fnd_concurrent.wait_for_request (request_id   => l_req_id,
                                       INTERVAL     => 1,
                                       phase        => l_req_phase,
                                       status       => l_req_status,
                                       dev_phase    => l_req_dev_phase,
                                       dev_status   => l_req_dev_status,
                                       MESSAGE      => l_req_message);

—   :SYSTEM.Message_Level := ’25’;
   COMMIT;

:SYSTEM.Message_Level := ‘0’;

   editor_pkg.report (l_req_id, ‘Y’);

/*for displaying the pdf automatically with a new window or tab after the concurrent request completes successfully*/
END;

This should provide you the desired functionality.

regards,

admin

Oracle E-Business Suite R12, a simple view for Active Application Users!

CREATE VIEW ERP_ACTIVE_USERS_V
AS
SELECT user_id, user_name, full_name
FROM fnd_user fu, per_all_people_f papf
WHERE papf.person_id = fu.employee_id
AND SYSDATE BETWEEN fu.start_date AND NVL (fu.end_date, SYSDATE)
AND SYSDATE BETWEEN papf.effective_start_date
AND NVL (papf.effective_end_date, SYSDATE)
ORDER BY 2;

regards,

admin

Oracle E-Business Suite 12.1.3 Templates, Deploying over VirtualBox using Oracle VM Server & VM Manager

 

When we decided to launch this blog, we made a promise to ourselves that we will never cut and copy something from a webpage or blog unless we try it out and make sure that, whatever we post here will be 100% tried out solution.

So guys, here we are once again, proving many geeks wrong and virtualizing the virtualization and bringing up Oracle 12.1.3 Vision instance, using Oracle VirtualBox!

Everything

We will publish a whitepaper towards setting up the entire exercises involved in setting up the entire stuff in coming days, sure guys it is bit too much and we need time to put everything in proper places! So stay tuned

follow @w7bugs on twitter. We will post the developments with the documentation(s)

Regards,

Admin

Oracle VM Templates, Are you sure you want to try them?

 

I have a application DBA friend who is good, knows his stuff and agreed to setup my home desktop machine with Oracle E-Business Suite R12 12.0.4 for certain kind of researches, even though I have access to three test instances at work!

After spending almost three years developing Oracle E-Business custom applications and reports, I just finished a full functional training on module Supply Chain Management from Oracle university, and I came across “Oracle VM Templates”, great, my life was just beautiful until

To run a vision instance all you need is 4GB of spare memory, 500GB storage, VirtualBox and Oracle Enterprise linux. Almost everything here other than the hardware part is free(?) to certain extends, I should had gone for it, instead I opted Oracle VM templates

Now, I needed to download around 37Gb (I already have Oracle supplied DVDs for R12 12.0.3, both 32/64bit) of template files, which come in .zip format. I need Linux environment to join them, OH YES, Oracle documentation for the same is great, provided you are BLIND

Now to use the downloaded templates (which are bundles of application and database tier, pre-configured and expected to run over virtual machines) I need Oracle VM server and Oracle VM Manager which runs only from linux environment (heh, did I say Oracle Linux Only?)

So in total I need 2 numbers of servers, ie, I run two virtual machines using VirtualBox, 1st one is used for a bare metal installation of Oracle VM server, Second is for Oracle Enterprise Linux, on top of which I  install Oracle VM Manager)

Ah, forgot to mention, I need two NICs to balance the network load, ie, my hopes to try out the VM templates from company provided hi-end laptop has just started fading….not entirely yet, though

So the story is becoming interesting, ain’t it? We will expand the story as much possible in coming days, until then, please share our joy, we just got our first hundred thousand hits…

 

for Windows7bugs

Admin

Oracle Inventory, Historical Inventory Values

Update: 11.Jan.2018

We’ve rectified the minor inventory value differences between the API generated values & the standard report “Inventory Value Report – by Subinventory” as due to the item costs those are used.

For average costing organizations, the report always generates the cut off date values again the current costs, instead of the costs those are populated to the intermediate tables.

IC_TOTAL_COST, the column that shows the cost as on cut off date is using the following formula

NVL(CIQT.rollback_qty,0) * DECODE(NVL(SEC.asset_inventory,1), 1, NVL(CIC.item_cost,0), 0) *:P_EXCHANGE_RATE IC_TOTAL_COST

following the same formula with the private API function has generated the same value as per the inventory report.

The updated API is packaged once again and available to download from here 

Update: 06.May.2013

Recently we received few comments about the inventory values generated using the below hack not matching the transaction historical summary report values (R12). We had gone through a series of exercises to evaluate such claims and confirmed that all those comments were valid. Below are the few possible explanations.

Though both the above said reports call the same API to populate inventory details, parameters passed into the API are slightly different.

For the report “Inventory Value By Subinventory” the API is called like following

CST_Inventory_PUB.Calculate_InventoryValue(
p_api_version => 1.0,
p_init_msg_list => CST_Utility_PUB.get_true,
p_organization_id => :P_ORG_ID,
p_onhand_value => 1,
p_intransit_value => 1,
p_receiving_value => 0,
p_valuation_date => to_date(:P_AS_OF_DATE,'YYYY/MM/DD HH24:MI:SS'),
p_cost_type_id => :P_COST_TYPE_ID,
p_item_from => :P_ITEM_FROM,
p_item_to => :P_ITEM_TO,
p_category_set_id => :P_CATEGORY_SET,
p_category_from => :P_CAT_FROM,
p_category_to => :P_CAT_TO,
p_cost_group_from => NULL,
p_cost_group_to => NULL,
p_subinventory_from => :P_SUBINV_FROM,
p_subinventory_to => :P_SUBINV_TO,
p_qty_by_revision => :P_ITEM_REVISION,
p_zero_cost_only => :P_ZERO_COST,
p_zero_qty => :P_ZERO_QTY,
p_expense_item => :P_EXP_ITEM,
p_expense_sub => l_exp_sub,
p_unvalued_txns => :P_UNCOSTED_TXN,
p_receipt => 1,
p_shipment => 1,
x_return_status => l_return_status,
x_msg_count => l_msg_count,
x_msg_data => l_msg_data
);

Parameter “p_intransit_value => 1” makes the entire scenario different from “Transaction Historical Summary” as the inventory values are calculated against the quantities including the quantities in transit also. Further, for Average cost organizations, the report calculates the values against the current date item costs (We are trying to get an explanation for the same from multiple oracle communities, including communities.oracle.com)

Further, the rollback date column, unless entered as cutoff date 23:59:59 (eg: 31-dec-2012 23:59:59) always rolls back to 31-dec-2012 00:00:00, thus not picking up lines whichever were processed later for the entered date.

On the other hand, Transaction Historical Summary report calls the API like following

CST_Inventory_PUB.Calculate_InventoryValue(
p_api_version => 1.0,
p_init_msg_list => CST_Utility_PUB.get_true,
p_organization_id => :P_org_id ,
p_onhand_value => 1,
p_intransit_value => NULL,
p_receiving_value => 0,
p_valuation_date => l_hist_date,
p_cost_type_id => NULL,
p_item_from => :p_item_lo ,
p_item_to => :p_item_hi ,
p_category_set_id => :p_cat_set_id ,
p_category_from => :p_cat_lo,
p_category_to => :p_cat_hi,
p_cost_group_from => :p_cg_lo,
p_cost_group_to => :p_cg_hi,
p_subinventory_from => :p_subinv_lo,
p_subinventory_to => :p_subinv_hi ,
p_qty_by_revision => NULL,
p_zero_cost_only => NULL,
p_zero_qty => NULL,
p_expense_item => NULL,
p_expense_sub => NULL,
p_unvalued_txns => 0,
p_receipt => NULL,
p_shipment => NULL,
x_return_status => l_return_status,
x_msg_count => l_msg_count,
x_msg_data => l_msg_data
);

Here the parameter “p_intransit_value => NULL” is set as NULL, thus the quantities in transit are not calculated. Further, the historical average costs are picked up for the transactions (material costs)

Further the rollback date is always expected to be entered like “31-dec-2012 23:59:59” in order to include the all the material transactions happened on the date.

So the in-transit quantity differences, item costs and the material transactions happened within the cutoff date time frame creates the variances what the user see with both the reports.

We had done the exercises more than few dozen times to reach to these unconfirmed conclusions. If as an experienced Oracle application user, dealing with Oracle inventory has any other explanations, Please, come ahead and we will amend the post with your valued inputs.

Requirement details: Oracle provides multiple standard reports to generate Inventories values on specified dates and depending upon the volume of transactions all these reports generate thousands of lines details to reach to such cut off date inventory values. Our requirement was to provide the auditors a quick view to inventory values as on end of each month, thus the entire development of below provided solution started.

How it works

Folder view supported form module developed by us calls a stored procedure, generates the rows into GLOBAL TEMPORARY tables and a stored function sum ups the material value and inserts into a local table (Base table with the form module)

For all the closed inventory periods, an insert statement picks up the values for the cut off dates from the view“cst_period_summary_v” and the months which are not already in the “cst_period_summary_v” view are populated by calling PVT APIs what we have heavily customized.

We achieved our goal by disabling the gather table statistics which are called from the PUBLIC API, then exclusively calling a COMMIT from the primary loop initiated by “populate history values” button press, thus indirectly flushing out the GLOBAL TEMPORARY TABLES for next run.

We hope this solution will be useful for organizations around the world who are running Oracle ERP 12.x.xx suites.

Oracle clearly states the API CST_Inventory_PUB  is private and shouldn’t be called by the users exclusively from any other procedures or packages. Please refer to :“Using Oracle API CST_Inventory_PUB Package ID 847101.1]”

Hence you are going to use the solution provided by us at your own risk (Ironically, this PVT API is nothing more than few select statements based on different parameters passed in)

 

Here we are providing a solution to populate inventory values until “last month” by a mere mouse click

image

The entire solution could be downloaded from here

Regards,

Admin

APP-ONT-251084 No Messages in the Stack

Updated: 25th October 2021

Another situation could be when the customer you have created doesn’t have Payment Terms set. Once the Payment Terms set, open the Sales Order that is stuck using Order organizer, set the payment terms on both header and line levels and try to book once again. This should solve the situation.

A user may be provided this particular error while trying to book a sales order. If checked in Oracle support documentation, you may not find much useful information addressing this particular error.

Our case, most of the times this error occured while users tried to book an order against a customer who doesn’t have site information for that particular organization. ie, Customer ‘ABC’ was created for organization ‘XYZ’ and users from organization ‘DEF’ tried to create sales orders for customer ‘ABC’. This issue could happen to any organization which has “multi-org” structure.

The first thing the consultant should check should be the customer site information for the organization, if the site information is missing, proceed towards creating it. Once the site information is updated, manually select the shipping address and other details and proceed to book the order.

If the error is not addressed after creating the site information, proceed to next level of trouble shooting. Metalink documentation points towards items not in price list and tax etc.
Metalink document id(s) : 396427.1, 988810.1