Functional module to change production order

Hi,
I tried with FM CO2H_PROD_ORDER_CHANGE
to change production order quantity field GAMNG value, but it did not work.
Please suggest me any FM or BAPI to change Production order quantity.
Thanks
Hema

Hi Ferry,
Thanks for your fast reply.
I tested with the function modules
KK_F_AFKO_AFPO_UPDATE
RK_AUFTRAG_SICHERN
First FM does not have GAMNG(total order qty) field.
With 2nd FM, it is directly updating table AUFK and AFPO with order qty and order qty. It will not update operation quantity, that is alsor required.
If we do manually in CO02 transaction, operation quantity also will update once we change the order quantity.
Thanks
Hema

Similar Messages

  • Need a function module to create production order with reference

    Hi
    I need a function module to create a production order with reference to an existing order. There is no BAPI available for SAP 4.7 release. I found that the function module CO_ZF_PRODUCTIONORDER_CREATE does not create with reference to an existing order.
    Any help will be rewarded.
    Pavan

    Dear Pavan,
    Unfortunately there is no FM for this..
    Cheers
    Nitesh

  • Function module for display production order details

    Hi All,
           I want to display production order details including operation,sub-operations and components using standard FM.I checked 4 FMs, but some are not displaying my require details. I found PM_ORDER_DATA_READ function module, it is displaying all details.But you can execute the function module 2 times for different orders it is giving ABAP dump 'itab_error'. Please get back to me if any one faced this problem or know solution.I am also checked BAPI_ALM_ORDER_GETDETAIL FM.
    My require fields are
    AUFNR, WERKS, PLNAL, PLNFL, VORNR,UVORN, ARBPL, KTSCH,
    LTXA1,OFFSTB,VGW01 etc.
    I am using SAP 4.7 release. Please send me either standard FM or BAPI to display all details of production order.
    Thanks in Advance
    Shaik Basha

    Hi,
    I had the same problem this morning and I found out a FM you have to run to fix this problem.
    FM: CO_IT_SET_FLG_ITAB_NEW
    Rgds,
    Parise

  • Function module for changing Work order user status in IW32

    Hi,
    I want to change the work order user status in IW32 using ABAP.
    Is there any function module to do so or any other way? I have tried using BDC but this does not work.
    Please suggest.
    Regards,
    Naba
    Edited by: n. saha on Nov 5, 2008 6:46 AM

    I am getting Same Problem.
    fi_methods-method = 'SAVE'.
    APPEND fi_methods.
    fi_methods-refnumber = 1.
    fi_methods-objecttype = 'USERSTATUS'.
    fi_methods-method = 'CHANGE'.
    fi_methods-objectkey = '002000002453'.
    APPEND fi_methods.
    fi_userstatus-user_st_text = 'COMM'.
    fi_userstatus-user_langu   = 'EN'.
    fi_userstatus-CHANGE_EVENT = ' 01 '.
    APPEND fi_userstatus.
    CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'
      TABLES
        it_methods    = fi_methods
        it_userstatus = fi_userstatus
        return        = fi_return.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    Above code I am using and there the message comes like
    T ID                   NUM           MESSAGE
    S IW                   080           Order saved with number 2000002453
    S IWO_BAPI2     110           BAPI control was ended
    can any on know what is wrong in this? please help if having knowledge.
    Thank You,
    Jahnavee Trivedi

  • Hi. i used Function module to change Characteristic values of a sales order

    hi. i used Function module to change Characteristic values of a sales order..
    but sales order's Characteristic values didn't change.
    And the Function module doesn't occur any log message.
    please tell me wrong code, and how to solve this problem.
    if i have wrong method, what data can i pass to change the characteristic values
    DATA: LT_E1CUVAL    TYPE TABLE OF E1CUVAL.
      DATA: WA_E1CUVAL    TYPE E1CUVAL.
      DATA: LS_CFG_HEAD   LIKE CUXT_CUCFG_S,
            LS_INSTANCES  LIKE CUXT_CUINS_S,
            LS_VALUES     LIKE CUXT_CUVAL_S,
            LS_E1CUCFG    LIKE E1CUCFG,
            LS_E1CUINS    LIKE E1CUINS,
            LS_E1CUVAL    LIKE E1CUVAL,
            LS_PROFILE    LIKE E1CUCOM,
            LS_VBAP       LIKE VBAP,
            L_CUOBJ       LIKE INOB-CUOBJ,
            L_ATINN       LIKE CABN-ATINN.
      DATA: LT_INSTANCES  LIKE CUXT_CUINS_S OCCURS 0,
            LT_PART_OF    LIKE CUXT_CUPRT_S OCCURS 0,
            LT_VALUES     LIKE CUXT_CUVAL_S OCCURS 0,
            LT_VAR_KEYS   LIKE CUXT_CUVK_S  OCCURS 0,
            LT_KSML       LIKE KSML         OCCURS 0 WITH HEADER LINE,
            BEGIN OF LT_CLINT OCCURS 0,
              CLINT  LIKE KSSK-CLINT,
            END OF LT_CLINT.
      DATA: LT_CUIB       LIKE CUIB_CUOBJ_S OCCURS 0 WITH HEADER LINE.
      DATA: E_ROOT_INSTANCE           TYPE     CUXT_INSTANCE_NO.
      DATA: EV_ROOT_PERSIST_ID     TYPE     IBEXTINST_DATA-EXT_INST_ID.
      DATA: EV_CFG_HAS_CHANGED     TYPE     XFELD.
      DATA: EV_HANDLE_APPL_LOG     TYPE     BALLOGHNDL.
      DATA: L_CUOBJ_NEW           TYPE CUOBJ.
      DATA: L_OWNER               TYPE IBXX_BUSINESS_OBJECT.
      REFRESH LT_E1CUVAL.
      CLEAR LS_VBAP.
      SELECT SINGLE CUOBJ INTO CORRESPONDING FIELDS OF LS_VBAP
                                FROM VBAP WHERE VBELN = I_VBELN
                                            AND POSNR = I_POSNR.
      IF SY-SUBRC <> 0.
        RAISE INSTANCE_NOT_FOUND.
      ENDIF.
      REFRESH LT_CUIB. CLEAR LT_CUIB.
      LT_CUIB-INSTANCE = LS_VBAP-CUOBJ.
      APPEND LT_CUIB.
      CALL FUNCTION 'CUCB_INITIALIZER'
        EXPORTING
          IT_INSTANCES = LT_CUIB[].
      CALL FUNCTION 'CUXI_GET_SINGLE_CONFIGURATION'
        EXPORTING
          I_ROOT_INSTANCE              = LS_VBAP-CUOBJ
        IMPORTING
          E_CFG_HEAD                   = LS_CFG_HEAD
          ES_PROFILE                   = LS_PROFILE
          ET_RETURN                    = ET_RETURN
        TABLES
          E_TAB_INSTANCES              = LT_INSTANCES
          E_TAB_PART_OF                = LT_PART_OF
          E_TAB_VALUES                 = LT_VALUES
          E_TAB_VAR_KEYS               = LT_VAR_KEYS
        EXCEPTIONS
          INVALID_INSTANCE             = 1
          NO_ROOT_INSTANCE             = 2
          INSTANCE_IS_A_CLASSIFICATION = 3
          INTERNAL_ERROR               = 4
          NO_PROFILE_FOUND             = 5
          INVALID_DATA                 = 6
          OTHERS                       = 7.
      IF SY-SUBRC <> 0.
        CASE SY-SUBRC.
          WHEN 1.
            RAISE INSTANCE_NOT_FOUND.
          WHEN 3.
            RAISE INSTANCE_IS_A_CLASSIFICATION.
          WHEN OTHERS.
            RAISE INVALID_DATA.
        ENDCASE.
      ELSE.
        LOOP AT LT_VALUES INTO LS_VALUES.
          IF    LS_VALUES-CHARC = 'SAP_MILLCA_PACKAGING'
             OR LS_VALUES-CHARC = 'PD_CA_PACKING_DM'.
            LS_VALUES-VALUE = '7100010'. "This is test data
            MODIFY LT_VALUES FROM LS_VALUES.
          ELSE.
            DELETE LT_VALUES WHERE CHARC = LS_VALUES-CHARC.
          ENDIF.
          CLEAR LS_VALUES.
        ENDLOOP.
      ENDIF.
    &#50689;&#50629;&#51221;&#48372; &#53945;&#49457; &#48320;&#44221;
      CALL FUNCTION 'CUXI_SET_SINGLE_CONFIGURATION'
        EXPORTING
          I_CFG_HEADER                        = LS_CFG_HEAD
          I_ROOT_INSTANCE                     = LS_VBAP-CUOBJ
        I_PLANT                             =
        I_STRUCTURE_EXPLOSION_DATE          =
        I_STRUCTURE_EXPLOSION_APPL_ID       =
        I_LOGSYS                            =
          IS_PROFILE                          = LS_PROFILE
        IV_ONLY_SINGLE_LEVEL                =
        IV_HANDLE_APPL_LOG                  =
        IV_OBJECT_APPL_LOG                  = 'CIF'
        IV_SUBOBJECT_APPL_LOG               = 'T_CNFG'
        IMPORTING
          E_ROOT_INSTANCE                     = E_ROOT_INSTANCE
          EV_ROOT_PERSIST_ID                  = EV_ROOT_PERSIST_ID
          EV_CFG_HAS_CHANGED                  = EV_CFG_HAS_CHANGED
          EV_HANDLE_APPL_LOG                  = EV_HANDLE_APPL_LOG
          ET_RETURN                           = ET_RETURN
        TABLES
          I_TAB_INSTANCES                     = LT_INSTANCES
          I_TAB_PART_OF                       = LT_PART_OF
          I_TAB_VALUES                        = LT_VALUES
          I_TAB_VAR_KEYS                      = LT_VAR_KEYS
        I_TAB_BLOB                          =
        EXCEPTIONS
          NO_CONFIGURATION_DATA               = 1
          NO_ROOT_INSTANCE                    = 2
          INVALID_INSTANCE                    = 3
          INSTANCE_IS_A_CLASSIFICATION        = 4
          INTERNAL_ERROR                      = 5
          NO_PROFILE_FOUND                    = 6
          INVALID_DATA                        = 7
          OTHERS                              = 8
      IF SY-SUBRC <> 0.
        CASE SY-SUBRC.
          WHEN 1.
            RAISE NO_CONFIGURATION_DATA.
          WHEN 3.
            RAISE NO_ROOT_INSTANCE.
          WHEN 3.
            RAISE INVALID_INSTANCE .
          WHEN 3.
            RAISE INSTANCE_IS_A_CLASSIFICATION.
          WHEN 3.
            RAISE INTERNAL_ERROR.
          WHEN OTHERS.
            RAISE INVALID_DATA.
        ENDCASE.
      ENDIF.
      COMMIT WORK.
    save configuration with next commit
      CLEAR: LS_INSTANCES.
      READ TABLE LT_INSTANCES INTO LS_INSTANCES INDEX 1.
    L_OWNER-OBJECT_TYPE = LS_INSTANCES-OBJ_TYPE.
      L_OWNER-OBJECT_TYPE = 'PVS_POSVAR'.
      L_OWNER-OBJECT_KEY  = LS_INSTANCES-OBJ_KEY.
      CALL FUNCTION 'CUCB_CONFIGURATION_TO_DB'
        EXPORTING
          ROOT_INSTANCE         = LS_VBAP-CUOBJ
          ROOT_OBJECT           = L_OWNER
        IMPORTING
          NEW_INSTANCE          = L_CUOBJ_NEW
        EXCEPTIONS
          INVALID_INSTANCE      = 1
          INVALID_ROOT_INSTANCE = 2
          NO_CHANGES            = 3
          OTHERS                = 4.
      IF SY-SUBRC > 1 AND SY-SUBRC <> 3.
        CLEAR LS_VBAP-CUOBJ.
        RAISE INTERNAL_ERROR.
      ELSEIF SY-SUBRC = 1.
        LS_VBAP-CUOBJ = L_CUOBJ_NEW.
      ENDIF.
    What's wrong?
    help me to solve this problem.
    Thanks a lot.

    <b>SD_SALES_DOCUMENT_READ</b> Reads sales document header and business data: tables VBAK, VBKD and VBPA (Sold-to (AG), Payer (RG) and Ship-to (WE) parties)
    <b>SD_SALES_DOCUMENT_READ_POS</b> Reads sales document header and item material: tables VBAK, VBAP-MATNR
    <b>SD_DOCUMENT_PARTNER_READ</b> partner information including address. Calls SD_PARTNER_READ
    <b>SD_PARTNER_READ</b> all the partners information and addresses
    <b>SD_DETERMINE_CONTRACT_TYPE</b>
    In: at least VBAK-VBELN
    Exceptions: NO CONTRACT | SERVICE_CONTRACT | QUANTITY_CONTRACT
    <b>SD_SALES_DOCUMENT_COPY</b>
    <b>RV_ORDER_FLOW_INFORMATION</b> Reads sales document flow of sales document after delivery and billing
    SD_SALES_DOCUMENT_SAVE create Sales Doc from the copied document
    SD_SALES_DOCUMENT_ENQUEUE to dequeue use DEQUEUE_EVVBAKE
    RV_DELIVERY_PRINT_VIEW Data provision for delivery note printing
    SD_PACKING_PRINT_VIEW
    SD_DELIVERY_VIEW Data collection for printing
    called from RV_DELIVERY_PRINT_VIEW, SD_PACKING_PRINT_VIEW
    RV_BILLING_PRINT_VIEW Data Provision for Billing Document Print
    regards
    vinod

  • Function module to change price of uploaded product

    Hi Gurus,
    is there any function module to change price of uploaded product info in crm
    regards
    Naveen
    Edited by: Naveen Kumar on Feb 13, 2009 12:05 PM

    condition record can modify using FM 'CNFPR_RECORD_PUT'

  • Function module/ Bapi for Sales order change

    Hi Experts,
    I require to have a Bapi/ function module to change a existing sales order to insert value in the field VBAP-SOBKZ.
    Please suggest.
    Thanks,
    Shibaji.

    HI,
    I have identified this Bapi but this Bapi does not contain the relevant field to update. Can you suggest any other Function module/ Bapi to update the field.
    Thanks & Regards,
    Shibaji

  • Function Module for Changing delivery date

    Hi Friends ,
        I am held up with a scenario of changing the delivery date while creating purchase order. Could you please suggest any function module to change the delivery date in purchase order if it is less than 5 days.
    With Regards ,
    Sudhir S
    Moderator message: please do some own research before asking.
    Edited by: Thomas Zloch on Feb 21, 2011 11:45 AM

    Hi praveen for u r requirement there is no need of any FM
    Try this code
    parameters:
      p_date like sy-datum,
      p_no type i.
    data:
      w_date like sy-datum.
    w_date = p_date - p_no.
    write: / w_date .
    it is enogh for u r requirement
    plzz reward if it is usefull...
    for any further quiries my mail id is [email protected]
    plzz dont forget to reward

  • Is there any function module to Change the System Status

    Dear ABAPers,
             I am working in the Customer Service Module.I want to change the System status.
    Is there any function module to change the System Status.
    Thanks & Regards,
    Ashok.

    Hi Ashok
    Service Order status update function module ?
    How to set the system status
    Check above threads,
    Regards,
    Syf

  • Table or Function module to get Internal order planning and Cost element pl

    Dear All,
    Table or Function module to get Internal order planning and Cost element planning.
    Internal order planning from T-code KO13.
    Thanks in advance.
    Regards,
    Ravi
    Edited by: Ravi Chandra on Sep 13, 2011 8:08 AM

    BPEJ, BPEG, BPEP

  • Function Module to Change / Update BOM Line Items

    Hi,
    I need a Function Module to Change / Update BOM Line Items.
    Please help.
    Thanks.

    Try this FM - CSAP_MAT_BOM_MAINTAIN

  • Function Module to change the master data attachments?

    Dear Experts,
    In SAP we can enclose the attachments for the Master data. Do we have any standard function module to change the Master data attachments.
    Let me know if any?
    Thanks and regards,
    Reddy

    Hi Reddy,
    Please make use of function module :
    BINARY_RELATION_CREATE_COMMIT
    For detailed information on how to use the FM please see the thread below:
    USE OF THIS fUNCTION MODULE
    Regards,
    Dilek A.

  • Function module to change date format

    hi
    is there any function module to change date format from 20080318 to 18.03.2008

    Hi,
    Use this FM  CONVERT_DATE_FORMAT            Convert date from yyyymmdd to ddmmyyyy format
    Regards,
    Jyothi CH.

  • Function module to change the date format

    hi guys
    is there any function module to change the date format
    from 08/28/2007(mm/dd/yyyy)
    to August 28, 2007.
    regards
    vamsi

    hi vamsi.,
    Use  CONVERSION_EXIT_SDATE_OUTPUT to get the month name,
    but it will give short form of the month name.
    if you want <b>long description of the month</b>,
    use this peice of code.
    PARAMETERS: V_DATUM(07) TYPE C. "(example input:12-2007)
      DATA:     V_MON(2)  TYPE C,
                V_YEAR(4)      TYPE  C,
                V_MONTHNAME(10) TYPE C,
                V_FULLDATE(30) type c.
    WRITE  V_DATUM+0(2) TO V_MON.
    SELECT SINGLE LTX FROM T247 INTO V_MONTHNAME
    WHERE        SPRAS = SY-LANGU
         AND       MNR  = V_MON.
    CONCATENATE  V_MONTHNAME  v_datum+3(4)
                      INTO V_FULLDATE  SEPARATED BY SPACE.  "(example output : December 2007)
                      write: v_fulldate.
    <i><b>Reawrd points if useful</b></i>
    Chandra

  • Function Module to change pricing condition in Agreement

    Hi Experts ,
    While creating purchase agreement (ME31L) BDC i want to change the pricing condition in the document at item level .
    Planing to use function modules to change the pricing condition after document is created .
    Any help in function module which will change the pricing condition in Agreement will be appreciated .
    Any other suggestion are also welcome (-: .
    Thank You .

    how to change the pricing consition in  agreement(ME31L)

Maybe you are looking for