How to catch return in BAPI_EQUI_CHANGE

hello all,
i am updating equipment details using BAPI_EQUI_CHANGE.
   CALL FUNCTION 'BAPI_EQUI_CHANGE'
     EXPORTING
       EQUIPMENT               = wa_itab-equnr
       DATA_GENERAL            = it_data_general
       DATA_GENERALX           = it_data_generalx
        DATA_SPECIFIC           = it_specific
        DATA_SPECIFICX          = it_specificx
**     DATA_FLEET              =
**     DATA_FLEETX             =
*      VALID_DATE              = SY-DATUM
*      VALID_TIME              = SY-UZEIT
    IMPORTING
**     DATA_GENERAL_EXP        =
**     DATA_SPECIFIC_EXP       =
**     DATA_FLEET_EXP          =
       RETURN                  = v_return
but i am unable to catch anything in V_RETURN(means sucess or error message).
no data is displayed under V_RETURN.
what colud be

Hi Vinay
Check in class CL_PHIN_EUQI method UPDATE_EQUI.
* update successful
IF ls_return IS INITIAL OR
ls_return-type CA 'IS'.
then its sucess else error
Nabheet

Similar Messages

  • How to Catch Return Code(RFC) in  XI

    Hi
    Can any help me out,
    I have a scenario , which is posting the data into SAPR/3 through RFC and alternately I would like to catch the exceptions . I need to catch return code in my scenrio, which will be show successfully posted or not as E or U.
    My RFC returning the error codes like E, S, and U..so these error codes i need to catch and update into my DATABASE.
    This is scenrio , i need to do very urgent manner..please let me know, should i use schronous or fault message types?
    please give me logical steps for how to do this?
    If it sync messae type, please tell me what is the output message type and input message type..
    thank you,
    Regards..rambarki!

    Hi Rambarki,
    Just for your information I'll tell you what all you have to develop to complete this scenario.
    <b>1></b> Two datatypes. one for the Request(data coming from JDBC Sender) and one for the Response(data going through JDBC Receiver).
    <b>2></b> Two corresponding Messagetypes.
    <b>3></b> Five Message Interfaces.
              i) OutBound/Async with Request.
             ii) Abstract/Async with Request.
            iii) Abstract/Sync with Request and Response.
             iv) Abstract/Async with Response.
              v) InBound/Async with Response.
    <b>4></b> Message Mapping
              i) Message Mapping between the Request and imported RFC.
             ii) Mapping between RFC.Response and Response.
    <b>5></b> Single Interface Mapping with Source as Abstract/Sync interface and target as RFC with two mapping programs corresponding to Request and Response.
    <b>6></b> Integration Process
             i) Create container element for request and response interfaces.
            ii) Receive step(Asynchronous), Send step(Synchronous), Send step(Asynchronous).
    Receiver Determinations
    i)   JDBC --> Integration Process (imported from IR)(OutBInterface: OutBound/Async, InBnterface: Abs/Async)
    ii)  Integration Process --> R/3 (OutBInterface: Abs/Sync, InBInterface: RFC with mapping program)
    iii) Integration Process --> JDBC. (OutBInterface: Abs/Async, InBInterface: InBound/Async).
    Hope this works for you.

  • How to catch errors in calling program when using SUBMIT ... AND RETURN ?

    Hi ,
    I am calling a report using submit and return statement from a function module. The report has select-options field for a date field. If user enters a date in low, which is greater than high, getting error message "Lower limit is greater than upper limit".
    How to catch this error without endup stoping on selection screen of the report?
    In the documentation, I read :
    Programs called with SUBMIT ... AND RETURN or CALL TRANSACTION cannot propagate exceptions to the caller, because exception objects are bound to the internal mode of a program.
    Is there any way to overcome this?
    Also my aim is to write a validation on the date selection-option to have the date range not more than 20 days.
    I am not sure of how to achieve this. 
    Is there a way to do validation of select-options data before submiting to the report ?
    Is there any standard FM to achieve this task?
    Thank you,
    Surya.
    Edited by: Surya on May 24, 2009 6:08 PM

    Hi Surya ,
    In your function module's code validate the date .
    If the low value of the date less than high and date period is not more than 20 then
    call transaction and in else condition raise exception.
    In your FM write like that - -
    IF   date-low LT date-high AND
                           date_difference LE '20' .
    CALL  TRANSACTION   'transaction'.
    ELSE.
    RAISE  ...........  " Raise the invalid date exception
    ENDIF.
    Regards
    Pinaki

  • How to get return value from Java runtime.getRuntime.exec?

    I'm running shell commands from an Oracle db (11gr2) on aix.
    But, I would like to get a return value from a shell comand... like you get with "echo $?"
    I use a code like
    CREATE OR REPLACE JAVA SOURCE NAMED common."Host" AS
    import java.io.*;
    public class Host {
      public static int executeCommand(String command) {
        int retval=0;
        try {
            String[] finalCommand;
            finalCommand = new String[3];
            finalCommand[0] = "/bin/sh";
            finalCommand[1] = "-c";
            finalCommand[2] = command;
          final Process pr = Runtime.getRuntime().exec(finalCommand);
          pr.waitFor();
       catch (Exception ex) {
          System.out.println(ex.getLocalizedMessage());
          retval=-1;
        return retval;
    /but I do not get a return value... because I don't know how to get return value..
    Edited by: user9158455 on 22-Sep-2010 07:33

    Hi,
    Have your tried pr.exitValue() ?
    I think you also need a finally block that destroys the subprocess
    Regards
    Peter

  • How to catch and display a link content in another portlet page?

    Can you tell me how to display a URL content into next page after an user click s on this link? I am developing a JSR 168 portlet under a Portal. I have 3 pages so far in my portlet. view.jsp, view2.jsp and IpByHourPage.jsp. view2.jsp displays a lis of IP address. When an user clicks on an IP in view2.jsp, it goes to IpByHourPage.jsp. How to catch the IP address such as 123.23.89.21 that an user just click displayed in IpByHourPage.jsp. I don't know why I got null value returned.
    Also, I don't know how to do a "go back to previous page". I want to go back to view2.jsp from IpbyHourPage.jsp
    Here is my code
    in view2.jsp
    <portlet:renderURL var="aURL">
    <portlet:param name="goto" value="IpByHourPage"/>
    </portlet:renderURL>
    <a href="<%=aURL.toString() %> "><%=MyIP%></a>
    in IpByHourPage.jsp
    <%
    String MyIPHour = request.getParameter("goto");
    %>
    <h1>IP Report by Hour ( <%=MyIPHour%> )</h1>
    <portlet:renderURL var="Ret_IPByHour">
    <portlet:param name="Ret_IPHourPage" value="Ret_IPByHourPage"/>
    </portlet:renderURL>
    <center> <a href="<%=Ret_IPByHour.toString() %> "><b>Choose Another IP</b></a></center>
    in my .java file
    protected void doView(RenderRequest request, RenderResponse response)
    throws PortletException, IOException, UnavailableException {
    response.setContentType("text/html");
    String MyBegDate = request.getParameter("BegDate");
    String MyEndDate = request.getParameter("EndDate");
    String MyNetworks = request.getParameter("networks");
    String MyYourName = request.getParameter("yourname");
    PortletURL renderURL = response.createRenderURL();
    renderURL.setPortletMode(PortletMode.VIEW);
    request.setAttribute("renderURL", renderURL.toString() )
    String GotoRenderAction = request.getParameter("goto");
    String MyIPHourAction = request.getParameter("Ret_IPHourPage");
    if ( (MyIPHourAction!=null) && MyIPHourAction.equals("Ret_IPByHourPage") )
    PortletRequestDispatcher kk = getPortletContext().getRequestDispatcher("/view2.jsp");
    kk.include(request, response);
    if (MyIPHourAction != null && MyIPHourAction.equals("Ret_IPByHourPage"))
    PortletRequestDispatcher mm = getPortletContext().getRequestDispatcher("/view2.jsp");
    mm.include(request, response);
    if (GotoRenderAction != null && GotoRenderAction.equals("IpByHourPage"))
    request.setAttribute("BegDate", "MyBegDate");
    request.setAttribute("EndDate", "MyEndDate");
    System.out.println("BegDate" + MyBegDate);
    System.out.println("Endate" + MyEndDate);
    PortletRequestDispatcher mm = getPortletContext().getRequestDispatcher("/IpByHourPage.jsp");
    mm.include(request, response);
    if(MyEndDate!= null )
    PortletRequestDispatcher prd = getPortletContext().getRequestDispatcher("/view2.jsp");
    prd.include(request, response);
    else if (MyEndDate==null && GotoRenderAction == null)
    PortletRequestDispatcher prd = getPortletContext().getRequestDispatcher("/view.jsp");
    prd.include(request, response);
    The problem for above code is the clicked single IP can not be displayed in IpByHourPage.jsp. and I cannot go back to view2.jsp from IpByHourPage.jsp. when I click "Choose Another IP"
    I find out that the MyBegDate and MyEndDate values are all null when I click Choose Another IP link. I got the following error message
    Caused by: javax.servlet.ServletException: Unparseable date: "null null"
         at org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:858)
         at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:791)
         at org.apache.jsp.view2_jsp._jspService(view2_jsp.java:651)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
    How to fix above problems. Thanks

    I think the problems are related to portletsession. But I don't know how to use it. How to put portletsession into doview method or my jsp pages. Can anyone tell me in my code? Thanks a lot.

  • How to catch exception throw bc4j

    Dear Forum
    I am user of JDeveloper Swing application.
    while exception throw from bc4j some particular
    type error such as (oracle.jbo.DMLException) JBO-26041
    message display.
    i want to catch error no 26041 inorder to display own
    messageBox.
    There is two methods
    1-:
    i used messageBundle class i overite message string but unable to change dialogBox,i want to use own dialog.
    2-:
    And i fund ,DML exception message return from JUErrorHandlerDlg class.So using this subclass how
    to catch and throw own message.
    Plase send me some code to write sub class of JUErrorHandlerDlg.

    You want this method System to throw an exception if the String[] is empty?
    public void system( ObjectOutputStream output, String cmd []  ) {
       if (cmd.length == 0)
          throw new IllegalArgumentException("Hey! This is an empty array!");
    //...rest of your method
    }You can choose for yourself which exception type is most appropriate. You can in theory always use the base Exception but is not very specific nor recommended. In this case, I think an existing unchecked exception such as IllegalArgumentException would be the most appropriate.

  • How to catch PL/SQL: ORA-04052 error?

    I need to execute a procedure that select remote objects but the remote db is a RAC DB and I only have access to one of the nodes, the remote RAC have load balancing enabled and the remote DBA can’t create a DB Service for my connection, so, I have to re-run the execution of my procedure until it connects successful to the remote DB through a db link, but I can’t catch the error ORA-12541: TNS:no listener.
    Someone knows how to catch the error??
    set serveroutput on
    declare
    function F_DATE return sysdate
    is
    ld_return date;
    begin
    begin
    select sysdate into ld_return from dual@dbl_bnvalores;
    exception
    when others then
    ld_return := f_date;
    end;
    return ld_return;
    end F_DATE;
    begin
    dbms_output.put_line('Remote sysdate: '||f_date);
    end;
    Error at line 2
    ORA-06550: line 2, column 26:
    PLS-00562: a function must return a type.
    ORA-06550: line 7, column 42:
    PL/SQL: ORA-04052: error occurred when looking up remote object BNSAFI.DUAL@DBL_BNVALORES
    ORA-00604: error occurred at recursive SQL level 1
    ORA-12541: TNS:no listener
    ORA-06550: line 7, column 7:
    PL/SQL: SQL Statement ignored

    I could confirm that you would never branch to the exception in case of no listener!
    So another possibility that comes to mind is to enclose the remote select in an execute immediate and only execute it if you could establish a connection via UTL_TCP:
    Something along those lines:
    michaels>  DECLARE
       conn               UTL_TCP.connection;
       l_date             DATE;
       no_listner_excep   EXCEPTION;
       PRAGMA EXCEPTION_INIT (no_listner_excep, -29260);
    BEGIN
       conn := UTL_TCP.open_connection ('fleet', 1569);
       EXECUTE IMMEDIATE 'select sysdate from dual@fleet_new'
                    INTO l_date;
       UTL_TCP.close_connection (conn);
       DBMS_OUTPUT.put_line (l_date);
    EXCEPTION
       WHEN no_listner_excep
       THEN
          DBMS_OUTPUT.put_line (SQLERRM (SQLCODE));
    END;
    ORA-29260: network error: TNS:no listener
    PL/SQL procedure successfully completed.

  • How can i return object from oracle in my java code using pl/sql procedure?

    How can i return object from oracle in my java code using pl/sql procedure?
    And How can i returned varios rows fron a pl/sql store procedure
    please send me a example....
    Thank you
    null

    yes, i do
    But i can't run this examples...
    my problem is that i want recive a object from a PL/SQL
    //procedure callObject(miObj out MyObject)
    in my java code
    public static EmployeeObj callObject(Connection lv_con,
    String pv_idEmp)
    EmployeeObj ret = new EmployeeObj();
    try
    CallableStatement cstmt =
    lv_con.prepareCall("{call admin.callObject(?)}");
    cstmt.registerOutParameter(1, OracleTypes.STRUCT); // line ocurr wrong
    //registerOutParameter(int parameterIndex, int sqlType,String sql_name)
    cstmt.execute();
    ret = (EmployeeObj) cstmt.getObject(1);
    }//try
    catch (SQLException ex)
    System.out.println("error SQL");
    System.out.println ("\n*** SQLException caught ***\n");
    while (ex != null)
    System.out.println ("SQLState: " + ex.getSQLState ());
    System.out.println ("Message: " + ex.getMessage ());
    System.out.println ("Vendor: " + ex.getErrorCode ());
    ex = ex.getNextException ();
    System.out.println ("");
    catch (java.lang.Exception ex)
    System.out.println("error Lenguaje");
    return ret;
    Do you have any idea?

  • How to catch Jbo-DML exception

    Dear Forum
    while exception throw from bc4j some particular
    type error such as (oracle.jbo.DMLException) JBO-26041
    message display.
    i want to catch error no 26041 inorder to display own
    messageBox.
    There is two methods
    1-:
    i used messageBundle class i overite message string but unable to customize size of dialogbox.
    2-:
    And i fund ,DML exception message return from JUErrorHandlerDlg class.So using this subclass how
    to catch and throw own message.
    Plase send me some code to write sub class of JUErrorHandlerDlg.

    Hello
    I also want to catch Exception if u r now able then plz send me the procedure
    [email protected]
    Thanks and Regards
    Prashant

  • How to catch SAP application errors in BPM.

    Hi,
    I have a IDOC to Soap Sync Scenario where I send the message to a Webservice. I have used a BPM since we need to catch the resposne of this message and map it to a RFC. For ex if I get a success resposne I need to map success if not than I need to catch the error and map it to the RFC. Now here in some cases like if the target system (webservice) is down than XI raises a sap application error:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Inbound Message
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIAdapterFramework</SAP:Category>
      <SAP:Code area="MESSAGE">GENERAL</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: Connection refused (errno:239)</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack />
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    Normally XI stops the process in these cases and does not proceed to the next step but I need to catch this message and map the content in the AdditionalText to the target RFC. Can anyone let me know how to catch this SAP Application Error in BPM and map it to the RFC.
    Thanks,
    Bhargav

    Hi Gaurav,
    As I have mentioned I need to catch the application error in the BPM. If you see the discussion that is mentioned after the blog you have mentioned it is stated that the fault messages or the application error cannot be caught in BPM.
    In the blog that you stated we can catch the fault message and map it to a message structure but only to that extent after that it would stop the BPM process at that step but would not proceed further as shown in the screenshot given in the blog it would fail as "application error restart not possible".
    I need to proceed further and capture this error to an RFC Structure and call a proxy.
    Here after the error it does not proceed to the next step.
    Thanks,
    Bhargav

  • How can I return my ipad 1 to pre OS5?

    how can I return my ipad 1 to pre OS5?
    Ive been reading the forums all over the place to find the solution to my ipad 1 continually crashing. it does it mainly in safari and the app store.
    Its really annoying when you're halfway through composing a long e-mail message and it just reverts back to the home screen.
    I'm perfectly happy to give up the advantages of IOs 5, because I would rather have a stable machine (like it used to be) than use the cloud and multitasking. (I don't use them anyway). I know that some of my apps might stop working but its more important to me that the basics work.
    cheers
    Andy

    You cannot downgrade the iOS.  Once you upgrade, you're stuck with it.
    Part of your problem is that your iPad is old and it probably having difficulty keeping up with the data and protocols for the newer software.  It's probably time to send a note to Santa. 

  • How do I return two values from a stored procedure into an "Execute SQL Task" within SQL Server 2008 R2

    Hi,
    How do I return two values from a
    stored procedure into an "Execute SQL Task" please? Each of these two values need to be populated into an SSIS variable for later processing, e.g. StartDate and EndDate.
    Thinking about stored procedure output parameters for example. Is there anything special I need to bear in mind to ensure that the SSIS variables are populated with the updated stored procedure output parameter values?
    Something like ?
    CREATE PROCEDURE [etl].[ConvertPeriodToStartAndEndDate]
    @intPeriod INT,
    @strPeriod_Length NVARCHAR(1),
    @dtStart NVARCHAR(8) OUTPUT,
    @dtEnd NVARCHAR(8) OUTPUT
    AS
    then within the SSIS component; -
    Kind Regards,
    Kieran. 
    Kieran Patrick Wood http://www.innovativebusinessintelligence.com http://uk.linkedin.com/in/kieranpatrickwood http://kieranwood.wordpress.com/

    Below execute statement should work along the parameter mapping which you have provided. Also try specifying the parameter size property as default.
    Exec [etl].[ConvertPeriodToStartAndEndDate] ?,?,? output, ? output
    Add a script task to check ssis variables values using,
    Msgbox(Dts.Variables("User::strExtractStartDate").Value)
    Do not forget to add the property "readOnlyVariables" as strExtractStartDate variable to check for only one variable.
    Regards, RSingh

  • How do I return an unopened refurbished iBook for a complete refund?

    I ordered a refurbished 14 inch ibook a while ago and it has been sitting in an unopened box ever since. It cost about $1050. I bought this before the new intel MacBook's came out, and now that they are out, they are much better than the ibook's. Plus the iBook 14 inch is a weird ratio.
    How would i return my unopened ibook for a complete refund and only pay like 50 bucks more for a new macbook?

    Welcome to Apple Discussions!
    It depends on the store you bought it from. Read the policies of the store you bought it from, if they are posted on the web. Your "awhile ago" doesn't tell us anything about the number of days. If you have no idea when you bought it, but bought it by credit card, you can usually call the store and ask them with your credit card number to verify when that was. Most stores I've seen have a time limit on returns. Some do not accept refurbished products back. It is best to check with the individual store.

  • I just updated iOS on my iPhone 5. What a shock!! Where is the premium look and feel I bought my iPhone for? If I wanted the lokale feel of iOS 7.0 I would have bought a much cheeper taiwanese smartphone. Please let me know how I can return to the origina

    I just updated iOS on my iPhone 5.
    What a shock!! Where is the premium look and feel I bought my iPhone for?
    If I wanted the lokale feel of iOS 7.0 I would have bought a much cheeper taiwanese smartphone.
    Please let me know how I can return to the original look and feel of the iPhone surface I bought my phone for.

    You had plenty of time to look at screenshots on the internet and read various blog posts about iOS 7.

  • How can I return multiple values with PL/SQL Web Services

    Hi,
    I'm new to developping Web Services. I'm doing some tests with JDeveloper and OC4J on my local machine with a Web Services based on a PL/SQL function within a package. Right now that function only returns one value. So the xml response only has one output.
    I'd like to know how can I return multiple values with my PL/SQL Web Service. For example, if I want to return an employee's name and id? And that the xml contains two output : <employee>, <empid>?
    Reginald
    ps : I have searched the forum and I couldn't find an answer to this question, if that has been discussed AND answered before, can you please post the link? Thanks

    Alright, I actually found my answer. Since this was asked I think as a followup somewhere else I'll give my answer.
    It is very simple, all you have to do is create an Object Type and then Return that object type. After that, JDeveloper will take care of everything and you will have an xml response with multiple values. Here
    {color:#ff0000}
    create or replace TYPE person AS OBJECT
    ( id_interv number,
    first_name VARCHAR2(50),
    last_name VARCHAR2(50),
    date_birth date
    );{color}
    Then your function used in your Web Service should look something like this :
    {color:#ff0000}
    function info_emp (p_empno IN VARCHAR2) RETURN person AS
    l_emp person := person(-1,'','','');
    BEGIN
    SELECT first_name
    ,last_name
    ,emp_no
    INTO l_emp.first_name
    ,l_emp.last_name
    ,l_emp.emp_no
    FROM emp
    WHERE upper(emp_no) = upper (emp_no);
    {color}
    {color:#ff0000}
    RETURN l_emp;
    EXCEPTION WHEN NO_DATA_FOUND THEN
    l_emp := person (-1,'n/a','n/a','n/a');
    RETURN l_emp ;
    END info_emp;{color}
    {color:#ff0000}{color:#000000}After that, this is what the xml response looks like :{color}{color}
    &lt;first_name xsi:type="xsd:string"&gt;John&lt;/first_name&gt;
    &lt;last_name xsi:type="xsd:string"&gt;Doe&lt;/last_name&gt;
    &lt;emp_no xsi:type="xsd:string"&gt;0250193&lt;/emp_no&gt;

Maybe you are looking for

  • I REALLY would like to know...

    ..just whyat it was that the web developers were thinking when they "created" this piece of work for the Z10. I just picked up my device today and am trying to fit it out with necessary apps, but this is a burden that is absolutely absurd.  Here's wh

  • Keyboard shortucts not working correctly in several programs since Leopard

    Since upgrading to Leopard, certain keyboad commands no longer work. I read since Expose uses the F9, F10 and F11 keys, these may not work in other programs. Final Cut Express recommended switching those keys to Control-F9, Control-F10, and Control-F

  • Tolerance for Invoice at header level

    Hi, In our business process we use unplanned delivery cost for freight. It is allowed upto 5% of purchase order value. If it is more than purchasing need to review with vendor. In this scenario I want to set the tolerance limit in LIV when ever invoi

  • Dynamically change sql query (from statement)

    Hi all, Is it possible to change the 'from statement' dynamically in report 6i? I have 3 identical tables with different names (each to collect data in different area) and I want to be able to dynamically change the sql query at run time so I can use

  • Why do embeded presentations from Prezi no longer work?

    Embeded interactive presentations from Prezi no longer work, when viewed on Firefox. They still work fine, when viewed on Google. This is a problem whether I am signed on or not.