Error Buff And Retcode In Oracle Apps
Contents |
values: 0 -- Success 1 -- Warning 2 -- Error Below is an example of a package where I can pass an employee number and it can return retcode and errbuf in oracle apps its full name. If no data found for the employee number passed, the errbuf and retcode parameters in oracle apps concurrent program will turn YELLOW with the message 'No Employee Found'. If there is any other error occurs, it will use of retcode and errbuf turn RED with SQLERRM message. ---------------------------------------------------------- -- Package Specification ---------------------------------------------------------- CREATE OR REPLACE PACKAGE apps.emp_test_pkg IS FUNCTION emp_name ( errbuff OUT NOCOPY VARCHAR2, retcode OUT NOCOPY VARCHAR2, p_emp_number IN NUMBER) retcode 2 in oracle apps RETURN VARCHAR2; END emp_test_pkg; / ---------------------------------------------------------- -- Package Body ---------------------------------------------------------- CREATE OR REPLACE PACKAGE BODY apps.emp_test_pkg IS FUNCTION emp_name ( errbuff OUT NOCOPY VARCHAR2, retcode OUT NOCOPY VARCHAR2, p_emp_number IN NUMBER) RETURN VARCHAR2 IS lv_emp_name VARCHAR2(300) DEFAULT NULL; BEGIN SELECT (papf.first_name || ' ' || papf.last_name) INTO lv_emp_name FROM per_all_people_f papf
Retcode Meaning
WHERE 1=1 AND papf.employee_number = p_emp_number; RETURN (lv_emp_name); EXCEPTION WHEN NO_DATA_FOUND THEN errbuff := 'No employee found for ' || p_emp_number; retcode := '1'; -- warning fnd_file.put_line(fnd_file.log, errbuff); RETURN (lv_emp_name); WHEN OTHERS THEN errbuff := SQLERRM; retcode := '2'; -- error fnd_file.put_line(fnd_file.log, errbuff); RETURN (lv_emp_name); END emp_name; END emp_test_pkg; / Posted by Aopu Mohsin Email ThisBlogThis!Share to TwitterShare to FacebookShare to Pinterest Labels: PL-SQL Post a Comment Newer Post Older Post Home Subscribe to: Post Comments (Atom) Search This Blog Archive ► 2015 (1) ► Apr (1) ► 2014 (7) ► Nov (1) ► Apr (1) ► Mar (2) ► Jan (3) ▼ 2013 (9) ▼ Dec (3) Oracle R12 EB-Tax SQL Query Concurrent Programs Warning-Error: ERRBUFF and RET... Oracle HR related API List ► Oct (3) ► Jun (1) ► Mar (2) ► 2012 (26) ► Dec (26) About Me Aopu Mohsin Known mostly as Aopu among his family, friend and relative-circle, Abul is an Oracle EBS Applications Consultant by profession, a Website designer by hobby, and a serious Audiophile by heart. Since 2004, Abul has worked wit
Concurrent Program As we all know there are two mandatory parameters that need to be pased for all the procedures called1.ERRBUFF2.RETCODE..
Based on the business process if there is any undefined exeception occured while runningRetcode Python
concurrent program, we can end the concurrent program with Error/Warning. Define ERRBUFF as retcode in unix the first parameter and Retcode as the second one. Mention the OUT variable type. CREATE PROCEDURE PROCEDURE_NAME (errbuf OUT nocopy in oracle VARCHAR2, retcode OUT VARCHAR2) The retcode has three values returned by the concurrent manager0-Success1-Success & warning2-Error http://appsr12help.blogspot.com/2013/12/errbuff-and-retcode.html we can set the concurrent program to any of the three status by using these values in the retcode parameter Example:======== BEGIN…..EXCEPTION WHEN OTHERS THEN FND_FILE.PUT_LINE(FND_FILE.LOG,'Unhandled exception occurred in package. ErrMsg: ‘||SQLERRM); retcode='2′;END; Even you can use fnd_concurrent.set_completion_Status to send the concurrent program to more status than success,error and warning. February 21, 2012/0 Comments/by Oracle ERP Apps GuideShare http://www.oracleerpappsguide.com/2012/02/retcode-errbuff-parameters-in-concurrent-program.html this entryShare on FacebookShare on TwitterShare on Google+Share on PinterestShare on LinkedinShare on TumblrShare on VkShare on RedditShare by Mail http://www.oracleerpappsguide.com/wp-content/uploads/2016/09/New-Logo.png 0 0 Oracle ERP Apps Guide http://www.oracleerpappsguide.com/wp-content/uploads/2016/09/New-Logo.png Oracle ERP Apps Guide2012-02-21 09:23:002012-02-21 09:23:00RETCODE & ERRBUFF Parameters in Concurrent Program 0 replies Leave a ReplyWant to join the discussion? Feel free to contribute! Leave a Reply Cancel reply Your email address will not be published. Required fields are marked *Comment Name * Email * Website Notify me of follow-up comments by email. Notify me of new posts by email. CategoriesCategories Select Category A.I.M(3) ADF(1) AME(4) AP(63) API(95) Apps Functional(282) Apps Technical(407) AR(44) ASCP(3) Basic Concepts(208) BOM(1) Bugs(5) CE(4) CRM(2) CST(1) DBA(15) DFF(1) Discoverer(10) EBS Tax(1) ERP(435) FA(8) FAQs(74) Flexfields(32) Forms Personalization(9) General(2) GL(48) HRMS(7) iExpenses(1) India Localization(1) Interface(14) Interview Questions(96) INV(128) iSupplier(1) Metalink(6) MULTI ORG(24) OAF(12) OM(26) OPM(12) Oracle(222) Oracle Alerts(6) Oracle AOL(88) Oracle Apps(473) Oracle Forms(32) Oracle Fusion(1) Oracle Manufacturing(10) Oracle Pricing(1) Oracle Reports(23) Oracle Videos(3) OUM(2) Payroll(1) PJM(1) PL SQL(74) PO(49) Query(94) R12(23) SAP(2) SCM(3) Scripts(162) Setups(17) SLA(10) SQL(86) SQL PLUS(8) SQL*LOADER(11) SRS(1) SRW Package(1) TCA(2) Tips N Tricks(161) Toad(122) Triggers(1) Web ADI(3) WIP(3) WorkFlow(13) WS
Management Accounting Operating System Operating System Android iOS Microsoft Coding Programming J2EE Languages Database Database Data Warehousing Oracle Applications Applications Clarify CRM Oracle Apps Peoplesoft http://www.geekinterview.com/question_details/34579 Siebel Software Testing Testing Testing Tools Miscelleanous Helpdesk Mainframe Networking SAP R/3 Web Interview Coaching Career Counseling Job Interview Interview eBooks Accounting eBook C eBook Citrix eBook Job Interview http://krishnareddyoracleapps.blogspot.com/2012/07/retcode-errbuff.html eBook Career Advice Career Change Jobs Help Projects Requests Resume Help Training Advice Engineering Chemical Engineering Civil Engineering Electrical Engineering Electronics Engineering Micro Processor Mechanical Engineering By Company Ask Question in oracle Home Interview QuestionsOracle Apps What is the value of retcode mandatory parameter in oracle apps procedures? Interview Candidate Sep 14th, 2006 3 12106 Oracle Apps Answer First Prev Next Last Showing Answers 1 - 3 of 3 Answers Shruti Sep 15th, 2006 Retcode is an OUT parameter. It can have 3 values (0/1/2)where 0 - Success1 - in oracle apps Success with wanings2 - Error
Was this answer useful?Yes Reply ram Sep 20th, 2006 there is another parameter for apps procedure errbuff Was this answer useful?Yes Reply ratnakar Jan 23rd, 2007 While registering procedure as concurent program there we need to declare two mandatary OUT parameters in procedure. 1.Errbuf 2.Retcode Errbuf : Errbuf is one the paramter which will define in pl/sql to store procedure to get error messges into log file. Retcode: this parameter will be used to get the status of the concurrent program. It will give the values 0 for sucess 1 for warning 2 for errors Ratnakar Reddy Was this answer useful?Yes Reply Give your answer: If you think the above answer is not correct, Please select a reason and add your answer below. - Reason - Answer is wrong Spelling Mistakes Duplicate Answer Inappropriate Answer Other Answer Question Click here to Login / Register your free account Name: Email: Answer: Insert Code: Code Language: JCL COBOL ABAP ASP C C for Macs ColdFusion C++ C# CSS Delphused properly..like setting the status of the conucrrent program and putting the log messages...i think it is better we make some rule like we make the program end in Error when ever there is a unidentified exception occurs based on your business rule... define ERRBUFF as the first parameter and Retcode as the second one...Dont forget to specify the out variable type in it...CREATE PROCEDURE SAMPLE_PROC (ERRBUF OUT VARCHAR2,RETCODE OUT VARCHAR2,p_1 varchar2)The retcode has three values returned by the concurrent manager0--Success1--Success & warning2--Errorwe can set our concurrent program to any of the three status by using these parameters...for exampleBegin.....Exceptionwhen others thenfnd_File.put_line(fnd_file.log,'Unhandled exception occurred in package.procedure'||SQLERRM);retcode='2';end;Even you can use fnd_concurrent.set_completion_Status to send the concurrent program to more status than success,error and warning..... Posted by Murthy Ganjam at 1:46 AM 2 comments: Labels: AOL Tuesday, January 20, 2009 FND_GLOBAL PACKAGE Recently i come accross a requirement to capture the requestidof the concurrent with in the concurrent program session...Even i am aware of the FND_GLOBAL package...But it didnt strike'at first go.....so i am writing this article for people who are not even awarethat this package exists..FND_GLOBAL package gives the most of the enviroment valuesTHis package should be used in database side only...use FND_PROFILE package to get these values in Forms.1.FND_GLOBAL.USERID --Returns userid 2.FND_GLOBAL.APPS_INTIALIZEprocedure APPS_INITIALIZE(user_id in number,resp_id in number,resp_appl_id in number);This is used to set the values userid and responsibilityid for a session3.FND_GLOBAL.LOGIN_ID -Gives login id4.FND_GLOBAL.CONC_LOGIN_ID--Not sure how to use this5.FND_GLOBAL.PROG_APPL_ID--Concurrent program application id6.FND_GLOBAL.CONC_PROGRAM_ID--Concurrent program id7.FND_GLOBAL.CONC_REQUEST_ID (Server)This will give the concurrent request id of the program which is calling the plsql package.. ln_Request_id:=FND_GLOBAL.CONC_REQUEST_ID; Posted by Murthy Ganjam at 10:33 PM 11 comments: Label