Creation of function module for updating the ztable

Hi,
I am sending the requirement for ceation of function module for updating the ztable.
Requirement----
Table Updation rule (New record)
While creating a new record the calling function will export the following to the table handling function.
Table field     Probable Values
ZORDERNO------->     Sales Delivery no in case of sales orderShipment no in case of transfer order
UNAME----
>     User ID
ZORDTYPE----
>     SALEOR in case of sales orderTRANSF in case of transfer order
ZREFDOCNO----
>Sales Order no in case of sales orderPurchase Order no in case of transfer order
ZREFDOCNO1----
>Delivery no in case of transfer order
The table handling function will calculate the following fields
Table field     Probable Values
ZREQNO----
>Running serial number (incremented by 1 for each new record)
ZREQDAT     -
>System date
ZREQTIME----
>     System time
ZSTATUS----
>OPEN (for all new records)
Before inserting a new record the table handling function will always check if a previous record exists for the same order / shipment no. if record exists the function will not insert a new record.
Table Updation rule (Status Update)
While updating a record the calling function will export the following to the table handling function.
Table field     Probable Values
ZORDERNO----
>Sales order no in case of sales orderShipment no in case of transfer order
ZSTATUS----
>CANCEL if cancellation successfulERROR if cancellation not possible (order already processed)
The table handling function will calculate the following fields
Table field     Probable Values
ZSTATDAT----
>System date
ZSTATTIME----
>     System time

Do you have to create/update new record in Ztable through Function Module ?
or you need to write FM only for validation?
Any how, you need to create a Program with Input values for the fields of Ztable, and for rest of fields the Value can be calculated based on input as per your requirement.
Let me know clearly what exactly u need ?
Regards,
Kiran

Similar Messages

  • Function module for updating the values in table VTTK

    Hi,
    I am working on a report in which I need to update the value of field tdlnr of table vttk for a particular shipment number. I need to do this using functional module and I am not been able to find one. If anyone knows answer to this plz help.
    Thanks in advance,
    Priyanka.

    As noted above, RETURN table must be supplied empty, it is for BAPI to return the messages back to the calling program. You simply need to define an internal table, pass it to BAPI as is and then analyze this table after the BAPI call. For example:
    DATA: BEGIN OF it_return OCCURS 0.
            INCLUDE STRUCTURE bapiret2.
    DATA: END OF it_return.
    CALL FUNCTION 'BAPI_SHIPMENT_CHANGE'
    <...>
      TABLES
    <...>
        return = it_return.
    LOOP AT it_return.
      MESSAGE
           ID      it_return-id
           TYPE    it_return-type
           NUMBER  it_return-number
       WITH
                   it_return-message_v1
                   it_return-message_v2
                   it_return-message_v3
                   it_return-message_v4.
    ENDLOOP.
    Hope this helps.

  • CRM function module to update the attribute in the classification TAB of BP

    Hi All,
    Can any body let me know if there is any functionmodule to update the CRM function module to update the attribute in the classification TAB of BP tcode.
    I have searched a lot i get FM to update the marketing attribute and not the attributes in the classification tab.
    Thanks in Advance
    Edited by: Sharath Kumar on Dec 2, 2010 4:48 PM

    For material bom: CSAP_MAT_BOM_CREATE
    and CSAP_ORD_BOM_CREATE for Order BOM.
    Regards,
    Ravi

  • Function Module for Posting the Delivery Doument

    Dear Experts,
            Could you please send me the Function Module for Posting the Delivery Doument.
    Thanks & Regards,
    Ashok.

    Hi,
    What do you mean by POSTING the delivery document?
    Are you mentioning the creation of Goods Issue?

  • Function Module to Update the values in STPO!! VERY URGENT!!!!!!!!!!!!!!!!!

    Hi All,
    Can any one tell me is there any Remote function module to update the values of components in STPO table while creating Sales order BOM, Material BOM, and WBS BOM. For example I want to update the Spare Part Indicator for Item components based on Plant.
    Please do the needful..
    Regards
    Yathish

    Hi Naren,
    Thanks for ur reply,
    The BAPI that you have gave is to update only Material BOM. But I want to Change  and create spare part indicator for 4 BOM's, ie Sales Order BOM, Eqipment BOM and also Material BOM and WBS BOM.
    Can u please shed some light on it,so that it would be helpfull to me.
    Thanks
    Yathish

  • Function module to update the values in STPO table :   VERY URGENT!!!!!!!!!

    Hi All,
    Can any one tell me is there any Remote function module to update the values of components in STPO table while creating Sales order BOM, Material BOM, and WBS BOM. For example I want to update the Spare Part Indicator for Item components based on Plant.
    Please do the needful..
    Regards
    Yathish

    For material bom: CSAP_MAT_BOM_CREATE
    and CSAP_ORD_BOM_CREATE for Order BOM.
    Regards,
    Ravi

  • Function module for updating COBRB table

    Hi,
    Is there any function module to update the entries in COBRB table.
    I have already tried the following but it's not updating ithe entries:
    1) k_settlement_rule_fill : get the objnr from PRPS and use it for CORBA and COBRB
    2)  k_settlement_rule_delete :  using  objnr only
    3) k_posting_rule_insert
    Regards
    Prabhat

    Hi,
    Please check this FM K_SETTLEMENT_RULES_UPDATE.
    Check FM AUC_SETTLEMENT_POST for sample codes.
    Regards,
    Ferry Lianto

  • Function Module to update the FI and Logistics Invoice

    Hi All,
    Is there any function module which updates the FI and Logistics Invoice simultaneously?
    Regards,
    Adapala M

    For material bom: CSAP_MAT_BOM_CREATE
    and CSAP_ORD_BOM_CREATE for Order BOM.
    Regards,
    Ravi

  • Function Module to update the sales order header status

    Hi,
      I am looking for a function module to update the Sales order header status.
      Pls. let me know if anybody has used any FM to update the SO status.
    Thanks,

    By mentioning status do you mean Object status or Document status??
    For Object status you may use FM: STATUS_MAINTAIN
    For document status it changes according to flow.
    Regards
    Eswar

  • Function module for converting the foreign currency to words

    hi,
    can anybody tell me about the function module for converting the foreign currency to words format.
    Like 25.50 USD
    should be "Twenty Five Dollar & Fifty Sents."
    foreign currency can be anyone like USD, JPY, EUR etc.
    Regards
    Nitin Varshney

    Hi,
    Try using the FM SPELL_AMOUNT
    Check this wiki
    [SPELL_AMOUNT|https://wiki.sdn.sap.com/wiki/display/Snippets/SpelltheAmountenteredin+words]
    Regards
    Sarves

  • Function module for displaying the location

    Hi,
          Could anyone tell  the Function module for displaying the location in our system  without a  file name while downloading, when the user press f4.
    thanks

    * read the default pathname on application server
      call function 'FILE_GET_NAME'
           exporting
    *           CLIENT                  = SY-MANDT
                logical_filename        = lc_logical_filename_ftappl
                operating_system        = sy-opsys
    *           parameter_1             = ' '
    *           PARAMETER_2             = ' '
    *           USE_PRESENTATION_SERVER = ' '
    *           WITH_FILE_EXTENSION     = ' '
    *           USE_BUFFER              = ' '
           importing
                emergency_flag          = l_emergency_flag
                file_format             = l_file_format
                file_name               = l_file_name_ftappl
           exceptions
                file_not_found          = 1
                others                  = 2.

  • Standard function module for checking the sales organization and plant

    Hi all,
        Does have standard function module for checking the relationship between sales organization and plant?
    Thanks a lot!
    Nina

    hi
    good
    check these BAPIS
    BAPI_SALESGROUP_GET_DETAIL     Sales Group: Display Name                                                
    BAPI_SALESOFFICE_GET_DETAIL    Sales Office: Display Name                                               
    BAPI_SALESOFFICE_GRP_EXIST     Sales Office / Sales Group: Existence Check                              
    BAPI_SALESORG_EXIST            Sales Organization: Existence Check                                      
    BAPI_SALESORG_GET_DETAIL       Sales Organization: Display Data                                         
    BAPI_SALESORG_OFFICE_EXIST     Sales Organization / Sales Office: Existence Check                       
    PLANT=>
    BAPI_PROMO_GETSITEPLANNING     Detailed Data for the Plants Involved in a Promotion   
    thanks
    mrutyun^

  • Function Modules for uploading the file

    Hi experts ,
                      I have a requirement to download a file (csv) from my local sytem (say desktop) into an internal table first and then update the contents of the same internal table into the database table.
    Can anybody provide me with a sample program for doing the same or at least the name of function modules for the same.
    Prompt replies will be rewarded.
    TIA
    Abhishek

    Hi Abhishek,
    How to use INSERT Statement..
    Check this Sample Program..
    TABLES:MARA.
    DATA:ITAB LIKE MARA OCCURS 0 WITH HEADER LINE.
    START-OF-SELECTION.
    ITAB-MATNR = '123ABCDA'. .
    ITAB-MBRSH = 'C'.
    ITAB-MTART = 'FERT' .
    ITAB-MEINS = 'KG' .
    APPEND ITAB.
    ITAB-MATNR = '123ABCDB'. .
    ITAB-MBRSH = 'C'.
    ITAB-MTART = 'FERT' .
    ITAB-MEINS = 'KG' .
    APPEND ITAB.
    LOOP AT ITAB.
    INSERT MARA FROM ITAB.
    MODIFY MARA .
    ENDLOOP.

  • Function modul for updating field contact in tab but000

    Hello experts,
    does anybody know a fm in order to update the field
    'contact' in tx bp , in tab strip status ?
    I have to update this field for many cp and in tx bp I only
    can select this field on tab strib status.
    Now I want to make a programm and so I need a fm.
    Thanks for help
    Gerd

    Hi Gerd,
    Look at function module 'BAPI_BUPA_CENTRAL_CHANGE' . The importing parameter CENTRALDATA has got field CONTACTALLOWANCE and that is what you are aiming to change.
    Don't forget to commit the changes.
    Cheers,
    Surendar
    Edited by: Surendar Sangwan on May 15, 2008 3:10 PM

  • Bapi Or Function Module for Updating a table

    Can u Plz let me know , is there any bapi or function module to update few fields of a standard table using an internable.

    Hi Shiva Kumar Tirumalasetty ,
         There is no FM / BAPI to update directly to any SAP tables . SAP won't suggests to develop a FM/BAPI like that , as it will cause some data inconsistency problem .
    We have to search and find BAPI's/ FM's for requirement specific if not exists then need to think about the alternate options (LSMW/ BDC etc..)
    Hope this answers your question.
    Thanks,
    Greetson

Maybe you are looking for