Updation of db tables through Function module

Using the below funtion module i need to update an internal table with 3 fields (Fkkop-opbel,fkkop-xblnr,fkkop-opord) into their respective tables
CALL FUNCTION 'FKK_DOCUMENT_CHANGE'
  EXPORTING
    I_OPBEL                           = v_OPBEL
  I_UPDATE_TASK                     = 'X'
TABLES
   T_CHANGEDOPS                      =   it_fkkop.
please can anyone tell me how.

hi,
chk this.
CALL FUNCTION 'Z_SAVE_SHIP_MET_TABLE'
        TABLES
          zmpets_ship_met_save = int_zmpets_ship_met.
FUNCTION Z_SAVE_SHIP_MET_TABLE.
""Update Function Module:
""Local Interface:
*"  TABLES
*"      ZMPETS_SHIP_MET_SAVE STRUCTURE  ZMPETS_SHIP_MET
modify zmpets_ship_met from table ZMPETS_SHIP_MET_SAVE.
ENDFUNCTION.
rgds
anver  pls mark hlpful answers

Similar Messages

  • Exporting Custom table through function module

    <b>How can i Export Custom table through function module.</b> when we add some table in the function module table tab it asks for a ref. table which is some table in database .. but i want to add some custom table with some user defined column names..how can i do this
    <b>n plz tell me how to loop thru select options</b>
    i have to loop thru select option and assign all the values to a variable.
    plz help me out
    Message was edited by:
            Karan Chopra

    Hi Karan,
    Do one thing, Just in the tables tab give the name of the table and don't write anything else. no TYPE and no ANY.
    Hope it will resolve issue.
    reward points if useful.
    Regards,
    Atish

  • UPDATE Table through Function Module

    Update delivery document LIKP wit new route LIKP-ROUTE. suggest the correct function Module

    Hi,
    Use BAPI
    BAPI_OUTB_DELIVERY_CHANGE  Change Outbound delivery
    In this BAPI a Parameter called HEADER_DATA of type BAPIOBDLVHDRCHG.
    There is field called Route, pass value in it.
    Also Set field ROUTE_FLG in Parameter HEADER_CONTROL   to X or U for Change.
    Thanks &regards,
    ShreeMohan

  • Updating a Base Table through a View having UNPIVOT function.

    Hi,
    I have a requirement of updating a Base Table through a View.
    This View has the query using a UNPIVOT function for displaying the columns of the Base tables in rows.
    I need to update/insert into/delete the Base Table by accessing the View (The user doesn't have an access to the Base Table, hence the DML's on the View).
    Following is the table I've created:-
    CREATE TABLE PERSON_DETAILS
      PID            VARCHAR2(10 BYTE),
      FIRSTNAME      VARCHAR2(1000 BYTE),
      LASTNAME       VARCHAR2(1000 BYTE),
      PHONENUMBER    VARCHAR2(1000 BYTE),
      ADDRESS1       VARCHAR2(1000 BYTE),
      ADDRESS2       VARCHAR2(1000 BYTE),
      COUNTRY_CODE   VARCHAR2(1000 BYTE),
      LANGUAGE_CODE  VARCHAR2(1000 BYTE),
      EMAIL          VARCHAR2(1000 BYTE)
    )The sample values are inserted in this table through the below script:-
    insert into person_details values ('1','XYZ','ABC','1234567890','India','Asia','IN','EN','[email protected]');
    insert into person_details values ('2','XYZ2','ABC2','1234567890','India','Asia','IN','EN','[email protected]');The code for the view is as below:-
    CREATE OR REPLACE FORCE VIEW PERSON_DETAILS_VIEW
       PID,
       CD_NAME,
       CD_VALUE
    AS
       SELECT "PID", "CD_NAME", "CD_VALUE"
         FROM person_details UNPIVOT INCLUDE NULLS (cd_value
                             FOR cd_name
                             IN  (firstname AS 'First Name',
                                 lastname AS 'Last Name',
                                 phonenumber AS 'Phonenumber',
                                 address1 AS 'address1',
                                 address2 AS 'address2',
                                 country_code AS 'Country Code',
                                 language_code AS 'Language Code',
                                 email AS 'Email') );Below are the values from the view:-
    PID CD_NAME         CD_VALUE
    1    First Name       XYZ
    1    Last Name       ABC
    1    Phonenumber  1234567890
    1    address1         India
    1    address2         Asia
    1    Country Code   IN
    1    Language Code EN
    1    Email               [email protected]
    2    First Name       XYZ2
    2    Last Name       ABC2
    2    Phonenumber  1234567890
    2    address1         India
    2    address2         Asia 
    2    Country Code   IN
    2    Language Code EN
    2    Email               [email protected] user would fire some statement like below:-
    update person_details_view
    set cd_value = 'US' where CD_NAME = 'IN'The above statement should update the base table PERSON_DETAILS.
    I understand I can write an INSTEAD OF trigger but I do not know what logic to write in the trigger so that the requirement gets fulfilled.
    My Oracle Version
    Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
    PL/SQL Release 11.1.0.7.0 - Production
    CORE    11.1.0.7.0    Production
    TNS for Solaris: Version 11.1.0.7.0 - Production
    NLSRTL Version 11.1.0.7.0 - ProductionAny help would be highly appreciated.
    Thank You,
    Ankit Khare.
    Edited by: Ankit_Khare84 on Jun 28, 2012 2:47 PM

    it is definitively possible with an instead of trigger.
    for Example:
    create or replace
    TRIGGER ioft_person
    INSTEAD OF UPDATE
    ON person_details_view
    FOR EACH ROW
    declare
    firstname1  person_details.firstname%type;
    BEGIN
                  SELECT firstname_new into firstname1
                  FROM   (SELECT pid, cd_name, cd_value
                          FROM  
                                  select * from person_details_view where (pid, cd_name) not in (select :new.pid, :new.cd_name from dual)
                                  union all
                                  select :new.pid, :new.cd_name, :new.cd_value from dual
                  PIVOT  ( max(cd_value) AS new FOR (cd_name) IN
                                                          ('First Name' AS firstname,
                                                            'Last Name' as lastname,
                                                            'Phonenumber' as phonenumber,
                                                            'address1' as address1,
                                                            'address2' AS address2,
                                                            'Country Code' as country_code,
                                                            'Language Code' as language_code,
                                                            'Email' as email
                  )  where pid = :old.pid;
      UPDATE person_details
      SET firstname = firstname1
      WHERE pid = :old.pid;
    END ioft_role_perm;and than run
    update person_details_view
    set cd_value = 'X|X' where cd_name = 'First Name' and pid=1The logic is: you must convert back the view through pivoting

  • Table or function module to update ibase

    Hi experts,
    I am using the transaction crmd_order to create a sales order and i am assigning the warranty product to it , now my requirement is, i have to update that warranty product in the ibase( ib52 ). so for that what is the table or function module i have to use to update the warranty information into the ibase.
    Thank you in advance.

    First Call CRM_IBASE_COMP_CHANGE and then   'CRM_IBASE_SAVE' and
      COMMIT WORK.

  • Save EAN11 field while creating POrder creation through Function module

    Hi All,
    I want to update EAN11 field in material master while creating Purchase Order through function module. I am using function module BAPI_PO_CREATE1 for creating purchase order. There are no structures in the PO creation FM in which EAN11 field is there. I have also tried using function module MEPO_DOC_ITEM_PROCESS for updating EAN11 field. It is not working. Please suggest some method to do that.
    Note: I am receiving EAN11 through an external system by proxy.
    Thanks,
    Chinmay

    Hi,
    Use BAPI_MATERIAL_SAVEDATA to updat ean numbers for materials.
    tables INTERNATIONALARTNOS is used to update EAN.
    Regards,
    Shanmugavel Chandrasekaran

  • Tables in Function Module

    Hi,
    Tables in function module are only export parameters or import parameter also?
    THANKS

    Hello,
    Tables in function module  are both import and export parameters.
    That means you can pass data to Function module through internal table (import parameter) and after
    some calculation in the function module you can update the same internal table and this internal table can also be passed to your calling program( export parameter).
    Regards
    Arindam

  • How Procurement cost can be captured in product master through functional module?

    Hi
    I have following Queries
    1) How Procurement cost can be captured in product master through functional module in SAP APO?
    2) How we can transfer procurement cost to product master in SAP APO through BAPI?
    Thanks
    Poorna

    Hi Poorna,
    Could you please check FM /SAPAPO/DM_PRODUCTS_POST.
    Table it_matloc of this FM can used to update Cost .

  • Generic Extraction business Requirement, through function module,

    Generic Extraction business Requirement, specifically through function module and source code in function module.

    Dear Karthik,
    Go to transaction SBIW -> Generic Datasource -> Maintain Generic Datasources -> Choose Master/Transaction Data -> Maintain proper entries (Application Component, Descriptions) -> Extraction by FM if you want to extract using FM.
    Maintaining Generic DataSources - Independently of application, you can create and maintain generic DataSources for transaction data, master data attributes or texts from any kinds of transparent tables, database views, InfoSets of the SAP query or using a function module. As a result, you can make use of the generic extraction of data.
    Creating a Generic DataSource
           1.      Select the DataSource type and give it a technical name.
           2.      Choose Create. The creating a generic DataSource screen appears.
           3.      Choose an application component to which the DataSource is to be assigned.
           4.      Enter the descriptive texts. You can choose any text.
           5.      Choose from which datasets the generic DataSource is to be filled.
                                a.      Choose Extraction from View, if you want to extract data from a transparent table or a database view. Enter the name of the table or the database view.
    After generation, you get a DataSource whose extract structure is congruent with the database view or the transparent table view.
    For more information about creating and maintaining database views and tables, see the ABAP Dictionary Documentation.
                                b.      Choose Extraction from Query, if you want to use a SAP query InfoSet as the data source. Select the required InfoSet from the InfoSet catalog.
    After generation, you now have a DataSource whose extract structure matches the InfoSet.
    For more information about maintaining the InfoSet, see the System Administration documentation.
                                c.      Choose Extraction using FM, if you want to extract data using a function module. Enter the function module and extract structure.
    The data must be transferred by the function module in an interface table E_T_DATA.
    For information about the function library, see the ABAP Workbench: Tools documentation.
                                d.      With texts, you also have the option of extraction from domain fixed values.
    Maintain the settings for delta transfer where appropriate.
           7.      Choose Save.
    Note when extracting from a transparent table or view:
    If the extract structure contains a key figure field, that references to a unit of measure or currency unit field, this unit field must appear in the same extract structure as the key figure field.
    A screen appears in which you can edit the fields of the extract structure.
           8.      Editing the DataSource:
           Selection
    When scheduling a data  request in the BW Scheduler, you can enter the selection criteria for the data transfer. For example, you may want to determine that data requests are only to apply to data from the previous month.
    If you set the Selection indicator for a field within the extract structure, the data for this field is transferred in correspondence with the selection criteria in the scheduler.
           Hide field
    You should set this indicator to exclude an extract structure field from the data transfer. As a result of your action, the field is no longer made available in BW when setting the transfer rules and generating the transfer structure.
           Inversion
    Reverse postings are possible for customer-defined key figures. For this reason, inversion is only possible for certain transaction data DataSources. These include DataSources that have a field that is indicated as an inversion field, for example, the field update mode in the DataSource 0FI_AP_3. If this field has a value, then the data records are interpreted as reverse records in BW.
    Set the Inversion indicator if you want to carry out a reverse posting for a customer-defined field (key figure). The value of the key figure is then transferred in inverted form (multiplied by –1) into BW.
           Field only known in exit
    You can enhance data by extending the extract structure for a DataSource using fields in append structures.
    The indicator Field only known in Exit is set for fields of an append structure. In other words, by default these fields are not passed onto the extractor from the field list and selection table.
    Deselect the indicator Field Only Known in Exit to enable the Service API to pass on the append structure field to the extractor together with the fields of the delivered extract structures in the field list as well as in the selection table.
    9. Choose DataSource -> Generate.
    The DataSource is now saved in the source system.
    Maintaining Generic DataSources
    ·        Change the DataSource
    To change a generic DataSource, in the initial screen of DataSource maintenance, enter the name of the DataSource and choose Change.
    You can change the assignment of a DataSource to an application component as well as the texts of a DataSource. Double-clicking on the name of the table, view, InfoSet or extract structure takes you to the appropriate maintenance screen. Here you can make changes required to add new fields. You can fully swap transparent tables and database views, but not InfoSets. If you return to the DataSource maintenance and choose Create, the screen for editing a DataSource appears. To save the DataSource in the SAP source system, choose DataSource  -> Generate.
    If you want to test extraction in the source system independently of a BW system, choose DataSource  ->  Test Extraction.
    ·        Delta DataSource
    In the Change Generic DataSource screen, you can delete any DataSources that are no longer relevant. If you are extracting data from an InfoSet, delete the associated query. If you want to delete a DataSource, this must not be connected to a BW system.
    Also visit :[Data Extraction from SAP Source System | http://help.sap.com/saphelp_nw04/helpdata/en/28/4c553c42360a40e10000000a114084/content.htm]
    Regards,
    Naveen.

  • Vendor-Customer balances in group currency-table/structure/function module?

    Hi All,
    Which table/structure/function module can be used to get balances for vendors and customers in group currency? We just wnat to extract balances in group currency so FBL1N and FBL5N are not options. Is there any SAP report which can provide these balances for both vendors and customers?
    Thanks and regards,
    Pinky

    Hi Pinky,
    I came across one report S_ALR_87012079 - Transaction Figures: Account Balance, Program RFSRRCUA, which extracts Account Balances of Vendor. Once the report is executed, you can do Currency Translation from one currency to different currencies. In the output screen, in the Top Menu, select 'Settings -> Currency' and you can convert to another currency. I am not sure, if this helps you. If this helps, kindly update your comments here.
    Thank you.
    Suresh Jayanthi.

  • Populate final table in Function module

    hi,
    please tell me the way to populate the final intenal table in function module, form four of the other tables with the corresponding data. i'd like to know how to move fileds of one table to other with maximum performance, can i user move-corresponding for the same.........

    hi,
    There are two ways to move the data ....
    1. You can loop through the table data and move the corresponding field on to your final internal table .
    2. You can directly assign the table value ...but remember the stucture of both the tables should be same.
    i.e,
    itab1[] = itab[].
    Regards,
    Santosh

  • Possible to trigger output type through Function module?

    Hi,
    Is it possible to trigger output type through Function modules or through some codings or any standard FM's?
    Regards
    Bala.

    You did not specify what area you need to retrigger an output type for, but here is a sample to retrigger a delivery output.
      CALL FUNCTION 'BAPI_LIKP_PROCESS_MSG_DIRECT'
        EXPORTING
      DYNAMICOUTPUTDEVICE       =
          processing                       = PROCESSING
      SORTMESSAGE               = 1
        TABLES
          deliverynumber                 = delnbrs
          outputtype                       = outputs
          messageprotocol              = bapimsgprot
          return                              = bapiret2.
    Thanks

  • Modify TRIP through function module( HRTRV_IF_MODIFY_TRIP )

    Hi Experts,
    I am trying to modify existing trip for employee through function module HRTRV_IF_MODIFY_TRIP in se37 in this i am passing employee no, trip no, framedata and in changing parameter fcode as "MOD". There is also a field as trip_guid whos value i don't know so left it blank. When i execute it in return table show message as "No suitable trip schema could be found".
    Can any one help me in this case. Our java developer using this fmi to change a trip.
    Thanks And Regards
    Ranjeet Singh

    Hi,
    The system tries to read a valid trip schema in table T706S and no relevant entry found.
    Sujay
    PS: Please don't post all bold
    Edited by: Sujay Venkateswaran Krishnakumar on Oct 15, 2010 4:54 PM

  • Problem regarding updation of Z-table through maintenance view

    hi ,
    I m facing problem in updation of Z-table through maintenance view (SM30).
    The scenario is that I have one customizing field in my Z-table which is checkbox.
    Now I need to populate 2 fields in Z-table on tick of this checkbox and clicking of SAVE button.
    For this I have created one module  ''change_field''  in PAI.
    Actually my database table is being updated but as soon as the control left my module all the updation that take place vanishes away.....
    So please help me in this matter.

    Thanks for ur previous effort it is updating the database but its effect is not shown immediately on screen.After i referesh the transaction it is dispalying the data.
    So can u please suggest me any way....
    Now i have one scenario infront of me....
    I need to restrict the data shown in maintenance view.
    I think it would be same as pop-up window displayed when we tick on 2nd radiobutton ("ENTER CONDITIONS")
    of intial screen of t-code SM30.
    Please suggest what shud i do....
    Thanks and reagrds,
    Amit
    Edited by: amit gupta on Jul 18, 2008 1:35 PM

  • Delete a Infocube Request  through Function module

    Hi Experts,
    I need to delete a request in Infocube through Function module. i have written a logic which request we have to delete, but i'm unable to find the exact function module to delete particular request.
    Quick response would be appriciated greatly and points will be assigned.
    Regards,
    Navin Achanta

    Hi,
    All the requests of InfoCube are available in table RSICCONT, so u create a function module to delete a records from this table.
    Hope this helps u a lot.........
    Assigning points is the way of saying Thanks in SDN
    Regards
    Ramakrishna Kamurthy

Maybe you are looking for

  • Can't print directly from web pages anymore-what setting needs to be changed?

    After doing a recent update for the printer, the program jammed up and I was forced to  uninstall then reinstall the printer. Since doing so, whenever I want to print a doc from a website, I right click to print, and a save page comes up-forcing me t

  • Creation of additional attachment in Java Mapping

    Hello all, I want to use a Java Mapping with the functionality to create a second /attachment which I can send over email out? I don’t want to pick this file somewhere from the server, instead I want to fill the content of the additional attachment d

  • WSConfig problem when connecting to Portal with Netweaver Business client

    Hello everybody, I am trying to connect to an existing portal (7.0) with the new Netwevaer Business client. On one system, it works - on the other, it doesn't. The client tries to call the url: http://<host>:<j2ee-port>/NavigationWS/NavigationWSConfi

  • Help Please: Glitches occurring with H.264 export

    Let me premise this post by acknowledging that I have little experience in the dslr video world. I'm trying to change that. I shot video for two fireworks shows this year as an experiment. I groomed the clips in After Effects (noise reduction, contra

  • Alternatives to iTunes?

    I've been using iTunes for over ten years, starting on my dual-USB iBook running System 9.  It's been a bumpy road at times, but I've now reached a point where there is little redeeming value in the bloated mess known as iTunes 11.  Does anyone have