BAPI for meter reading order (MRO) Reversal

Hi Experts,
Please let me know if there is any FM or BAPI for meter reading order reversal, Similar to EL37
Regards
Bikas

Hello Bikas,
Though this is an old post, thought of replying for the sake of googlers who might look for a solution for your query...the below code works!
*---Begin Of Code
  TYPES : BEGIN OF ty_meter_orders_data,
           anlage   TYPE eablg-anlage,
           adatsoll TYPE eablg-adatsoll,
           ablesgr  TYPE eablg-ablesgr,
          END OF ty_meter_orders_data.
  DATA : lt_meter_orders_data TYPE STANDARD TABLE OF ty_meter_orders_data,
              xy_ieabl_delete   TYPE  eabl_tab,
              xy_ieablg_delete  TYPE  eablg_tab,
              xy_ietrg_delete   TYPE  etrg_tab,
              x_anlage type anlage,
              x_retro_upd_date type adatsoll,
              y_return type char1.
  DATA : y_obj TYPE  isu17_meterread.
*--Get the needed data for reversal
  SELECT a~anlage
         a~adatsoll
         a~ablesgr
    FROM eablg AS a
    INNER JOIN eabl AS b ON a~ablbelnr = b~ablbelnr
    INTO TABLE lt_meter_orders_data
    WHERE a~anlage = x_anlage AND
          a~adatsoll >= x_retro_upd_date AND
          b~ablstat = '0'. "MR Order
  IF sy-subrc = 0.
    SORT lt_meter_orders_data BY anlage ablesgr adatsoll.
    DELETE ADJACENT DUPLICATES FROM lt_meter_orders_data COMPARING anlage ablesgr adatsoll.
    SORT lt_meter_orders_data BY adatsoll DESCENDING.
    LOOP AT lt_meter_orders_data ASSIGNING FIELD-SYMBOL(<fs_meter_orders_data>).
      CALL FUNCTION 'ISU_O_METERREAD_OPEN'
        EXPORTING
          x_anlage              = <fs_meter_orders_data>-anlage
          x_adatsoll            = <fs_meter_orders_data>-adatsoll
          x_ablesgr             = <fs_meter_orders_data>-ablesgr
          x_select2             = '5'
          x_wmode               = '6'
        IMPORTING
          y_obj                 = y_obj
        EXCEPTIONS
          not_found             = 1
          foreign_lock          = 2
          internal_error        = 3
          input_error           = 4
          existing              = 5
          number_error          = 6
          general_fault         = 7
          system_error          = 8
          manual_abort          = 9
          gasdat_not_found      = 10
          no_mrrel_registers    = 11
          internal_warning      = 12
          not_authorized        = 13
          not_qualified         = 14
          anpstorno_not_allowed = 15
          already_billed        = 16
          dev_already_prep      = 17
          OTHERS                = 18.
      IF sy-subrc = 0.
        CALL FUNCTION 'ISU_O_METERREAD_ACTION'
          EXPORTING
            x_okcode             = 'PSAV'
          CHANGING
            xy_obj               = y_obj
          EXCEPTIONS
            cancelled            = 1
            failed               = 2
            action_not_supported = 3
            system_error         = 4
            input_error          = 5
            not_customized       = 6
            OTHERS               = 7.
        IF sy-subrc = 0.
          CALL FUNCTION 'ISU_O_METERREAD_ACTION'
            EXPORTING
              x_okcode             = 'SAVE'
            TABLES
              yt_eabl_delete       = xy_ieabl_delete[]
              yt_eablg_delete      = xy_ieablg_delete[]
              yt_etrg_delete       = xy_ietrg_delete[]
            CHANGING
              xy_obj               = y_obj
            EXCEPTIONS
              cancelled            = 1
               failed               = 2
              action_not_supported = 3
              system_error         = 4
              input_error          = 5
              not_customized       = 6
              OTHERS               = 7.
          IF sy-subrc = 0.
            COMMIT WORK.
          ENDIF.
        ENDIF.
        CALL FUNCTION 'ISU_O_METERREAD_CLOSE'
          CHANGING
            xy_obj = y_obj.
* Implement suitable error handling here
      ELSE.
        y_return = 'E'.
      ENDIF.
    ENDLOOP.
    IF y_return <> 'E'.
      y_return = 'S'.
    ENDIF.
  ELSE
*    RAISE no_mtr_read_ordrs_found.
  ENDIF.
*---End of Code
Thanks.
Mohammed.

Similar Messages

  • Function Module/BAPI  for Meter Reading Entry(EL28)

    Hi Experts,
    Can anyone tell me about BAPI/Function Module for EL28(Meter Reading Entry).Standard FM is preferable.
    Thanks & Regards,
    Radharaman Haldar
    Moderator note - Thread locked, no research.
    Edited by: William Eastman on Mar 8, 2011 5:17 PM

    ISU_VALIDATION_DEPENDENT & ISU_DETERMINE_VALIDATION.
    The above two function module is used for the validation of Plausible or Implausible meter reading.

  • BAPI or FM to Create a Meter Reading Order

    Hi,
      Can anyone suggest me the name of a standard BAPI or any standard function module which can create a Meter Reading Order. I tried with ISU_S_METERREAD_CREATE but it is not creating the order, don't know why.
      Please Help.
    Regards,
    Kirti Bhushan.

    Sometimes ,BAPI´s are executed without errors (sy-subrc = 0 ) and don´t create the item (order,invoice etc.).
    That´s why you have to do a commit work after execution :
    CALL FUNCTION BAPI ****
    IF sy-subrc = 0 .
    commit work.
    endif.

  • Blocking creation of meter reading order for perticular installation

    Hi,
    I want to block creation of meter reading order for perticular installation within an MRU.
    This meter is disconnected in the installation.
    My requirement is if i create meter reading orders for  MRU it should not create MR oder for some installtions.
    your input on the same will be highly helpful.
    Thanks in advance.
    Regards,
    chetan

    Hi,
    Use Blocking Reason in ES31 (installation: Billing/Meter Reading control Tab)...During meter reading order creation, prevents meter reading orders from being created for the registers allocated to the installation.

  • BAPI / FM to create meter read order   (  Tcode  EL01)

    Hi All ,
    Is  there any BAPI or Function module to create meter read order  (Tcode EL01) .   Thanks in advance.
    Regards
    Neetesh

    use :
    ISU_S_METERREAD_CREATE

  • For few devices Meter Read order 09 information created automatically.

    Hi,
    In our one of the clients ISU system for EVC meters two Information read Orders are automatically created few days before every 01 order creation for the particular device.  Please provide the information due to what the Information Read order 09 is created .
    With Regards

    Check Meter control group is filled in register data of device. Control group allows to create multiple meter reading order in between periodic billing with meter reading reason
    09.Please make control data blank from device modification transaction if
    interim meter reading order is not required.
    Thanks,
    Laxmi.

  • Creation of Meter Reading Order

    Hi,
    My uploading program creating Meter Reading order using the function module ISU_S_METERREAD_CREATE. MRO is created Successfully for Meter Reading Reason 06. The Problem is Metering scheme is not Displaying in the Table EANL for the particular Subinstallation.
    Any one help me pls.
    Thanks in Advance
    Lakshmi

    Hi,
    Use Blocking Reason in ES31 (installation: Billing/Meter Reading control Tab)...During meter reading order creation, prevents meter reading orders from being created for the registers allocated to the installation.

  • Automatic creation of meter reading order with RR 01 after move in

    Hi Experts,
    I am working with DM module of SAP ISU. Currently I am facing a problem that after move-in a periodic order with RR 01 is created automatically by the system.
    Ex: Move in date is 01.01.2010. Monthly Portion is used with Schedule record 01.01.2010, 01.02.2010, 01.03.2010, 01.04.2010 and so on.
    If current system date is 20.07.2010 then Meter reading order is created automatically by the system for sch MRD 01.08.2010.
    Please let me know how to overcome this problem
    Thanks in advance.

    Thanks for your reply but I have cheked SPRO setting the suggested check box is already uncheked.
    I beleive the setting you have suggested is meant for default meter reading during move in but my problem is automatic creation of meter reading order with reason 01 during move in

  • Meter reading order simulation

    Hello experts,
    I need to "simulate" meter reading order creation process, to download orders (EL35, with specific formkey) and use the file for external system.
    Is this possible?
    Thanks,
    Angela

    Hello Olivia,
    thank you for your answer, but i'm afraid I don't understand it properly.
    I thounght  ISUMSORDER was for working order not for meter reading; is it not correct?
    I need to simulate meter reading order, I mean to use EL35 but without filling db tables EABL/EABLG.
    thanks,
    Angela

  • Move in -Move out  and Aperiodic meter reading order, No auto service Ord

    Hi ISU Experts,
    I have a following problem in ISU,
    When create a Move In or a Move out, the system should automatically create a Meter read Order and a Service Order in the Background.
    Same case  is applicable for the Aperiodic meter read order, whenever I create a Aperiodic meter read order, the system should create a service order/ notification automatically in the background,
    As mentioned above, In both the cases no service order/notifications is getting cretaed.
    I have maintained the SPRO settings for Aperiodic meter reading and for Move in and Move out , the service order creation checkbos is checked.
    Please anybody can throw some light, help me out what may be the problem, or any other SPro settings are to be maintained, any enhancement has to be done.
    Your inputs will be highly appericiated .
    Best Regards
    Suresh

    Hi,
             I am stuck with the same issue. I have checked the check box to create service order/notification from the meter reading order. Please let me know if you have found any resolution
    Thanks,
    Dhana

  • T-Codes/Steps for Meter Reading

    Hi,
    Can you pls send me the steps in creating a Meter Reading till its end.
    I mean the t-codes in order.
    thx
    guru

    Hi:
    First step in the meter reading process is to create meter reading and billing orders.
    Next there are a number of menu options available to enter and correct meter reading results.
    The monitoring option allows you to follow the status of Meter Reading orders during the process from creation through entering results onto creating a billable billing order.
    After collecting the meter reading results they need to be entered into the IS-U system. ISU offers several functions for this.
    Hopefully it would be helpful to find out the way.
    Regards
    Shashi

  • BAPI for converting planned order to Production Order(in PP)?

    Hi all,
            Is there any standard BAPI for converting Planned order to Production Order?
    Thanks in advance,
    anjaly

    hi,
    check this..
    BAPI_PRODORD_CREATE_FROM_PLORD BAPI: Convert Planned Order into Production Order
    for more details check this link..
    Create a production order
    <b>reward points if it is helpful..</b>

  • BAPI for Open production orders

    Hi All,
    Any BAPI for open production orders?.... Using BAPI i want to upload open production orders informatiomations.... Please help
    Thanks & Regards
    Santhosh

    Hi,
       Please check the following BAPI,
    Goto BAPI tcode, select hierarchical tab
      Production orders,ProductionOrder ,ProdOrdConfirmation , RCVPRORDCF and check the BAPIs

  • BAPI for Mass Purchase Order Confirmation

    Dear All,
    In standard SAP,it is possible to confirm for single line item only by using confirmation tab.
    We want to confirm Mass PO Confirmation.
    Is there any BAPI for Mass Purchase Order Confirmation?
    Regards,
    Ramesh

    Hi Sumant,
    I have tried with TC:MASS.
    By using this TC we can update quantity but not  delivery date & Confirmation Control (Fields available in the confirmation tab of ME22n for Vendor Confirmation).
    Is there any way to updates all these fields which are available in the Confirmation Tab?
    Is there any BAPI which is tranferring confirmation tab details into EKES table?
    Expecting your valuable inputs in this regard.
    Regards,
    Ramesh

  • BAPI for return sales order

    Hi,
    what BAPI that can be used for Return Sales Order? BAPI SALES_ORDER_CREATEFROMDAT2 cant work, I get return message as error : 'Unpermitted combination of business object BUS2032 and sales document type category H'.
    thanks alots.
    Alia

    Hi Alia,
    Go to transaction BAPI, and in the tree go to :
    Sales and Distribution -> Sales -> SalesOrder
    You will have a list of all the BAPI for the Sales Order. If you want a list of Sales Order, maybe you need the GetList BAPI : BAPI_SALESORDER_GETLIST
    Rgd
    Frédéric

Maybe you are looking for

  • Mid 2014 13" rMBP - Image Persistence

    Good Morning, Last night I came across an image persistence issue that seems to plague most rMBP users that have been supplied with an LG Panel. I'd like to confirm that this issue is still present in Apple's most recent iteration of the Macbook Pro

  • How do i access pictures in icloud on my iphone?

    I traded to an iphone 5s from the 4s.  My pics from the 4s were save to Icloud, is there a way to access the pics from my new Iphone?

  • NEW TO SSD

    Hi, guys. I will be getting a Intel SSD soon, probably this friday. I have no idea how to install a SSD in a macbook pro. My friend told me that the only thing I do is take out the factory HDD, and install the SSD. Is that simple? Do I need to concer

  • IPhone screen is dark. I can receive calls but can't make them because I can't see the numbers on the screen. Is there anything I can do about that?d

    My phone got damp. It wouldn't work for about a week. Now the screen is completely dark, altho I can receive calls. I just can't make a call because I can't see the numbers.  Anything I can do about that? Is this a simple repair?

  • Invoice and Tax layout

    Hello. I am trying to create an Invoice template. Here in Prince Edward Island, Canada the Taxes are Laid out as follows: Amount of Sale $100.00 GST (6%) $6.00 Sub-Total $106.00 PST (10%) $10.60 Total Payable $116.60 Does anyone know how to set this