Type conflict in function module parameters

Hi All,
i hve to pass dynamic field <dyn_field> into function module parameters but  it's giving a dump for type conflict.
where VALUE2  data type in 'AUTHORITY_CHECK' is UST12-VON but if i define <dyn_field> type UST12-VON . then it'll give dump in *ASSIGN COMPONENT  SECURITY_TABLE-FIELDNAME  of structure <wa> to <dyn_field> *.
SECURITY_TABLE-FIELDNAME  data type is different with UST12-VON .
pls guide me how to pass *<dyn_field> in fm parameters.
FIELD-SYMBOLS: <dyn_field> type any.
  LOOP AT <DYN_TABLE_IN> INTO <WA>.
        ASSIGN COMPONENT  SECURITY_TABLE-FIELDNAME  of structure
             <wa> to <dyn_field> .
        CALL FUNCTION 'AUTHORITY_CHECK'
          EXPORTING
            USER                = QUSER
            OBJECT              = SECURITY_TABLE-AUTHOBJCT
            FIELD1              = 'ACTVT'
            VALUE1              = '03'
            FIELD2              = SECURITY_TABLE-FIELDNAME
            VALUE2              = <dyn_field>

Hi anuj ,,
Can you explauin the solution ..
Regards

Similar Messages

  • Problem in  using function module parameters in abap program

    i want to use the coding present in on one of the function module 'AS_API_INFOSTRUC_FIND'  i got the problem using the function module parameters in my abap program.
    these are the parameters inside fm
    ""Lokale Schnittstelle:
    *"       IMPORTING
    *"             VALUE(I_FIELDCAT) TYPE  AIND_FCAT
    *"             VALUE(I_FIELDS) TYPE  TABLE OPTIONAL
    *"             VALUE(I_OBLIGATORY_FIELDS) TYPE  TABLE OPTIONAL
    *"       EXPORTING
    *"             VALUE(E_INFOSTRUC) TYPE  AIND_DESC
    *"             REFERENCE(E_ALL_FIELDS) TYPE  TABLE
    *"             REFERENCE(E_MATCHING_FIELDS) TYPE  TABLE
    *"       EXCEPTIONS
    *"              NO_INFOSTRUC_FOUND
    i want to declare     E_ALL_FIELDS  parameter    in my abap program,
    i have declared as 
    data: E_ALL_FIELDS TYPE TABLE.
    but   the system throws error that
    'type of field 'TABLE'  is generic .no table line has been specified'.
    i want to use it in my abap program how can i declare in my abap program .

    You have to declare the table using any specific type.
    The type table in the FM is generic so you can pass any type you need.
    For instance:
    TYPES: BEGIN OF ty_fields,
             fieldname LIKE dfies-fieldname,
           END OF ty_fields,
    TYPES: TY_T_GLU1              LIKE GLU1                     OCCURS 0,
           ty_t_fields            type ty_fields                occurs 0.
      DATA: lt_info_struct_fields TYPE ty_t_fields WITH HEADER LINE,
            lt_matching_fields    TYPE ty_t_fields WITH HEADER LINE.
        CALL FUNCTION 'AS_API_INFOSTRUC_FIND'
             EXPORTING
                  i_fieldcat         = ft_fieldcat-fieldcat
                  i_fields           = ft_fields_filled[]
             IMPORTING
                  e_infostruc        = lv_info_struct_name
                  e_all_fields       = lt_info_struct_fields[]
                  e_matching_fields  = lt_matching_fields[]
             EXCEPTIONS
                  no_infostruc_found = 1.

  • Processing Idoc type DELVRY05 whith  function module IDOC_OUTPUT_DESADV01

    Hi experts,
    I want to send automatically  an IDOC type DELVRY05 while saving the outbound delivery. i set the output message for shippement and the Outbound EDI parameters for the ship to party.
    When I'm processing the output message in VL02N, i'm having the following message:
    <<IDoc type DELVRY05 cannot be processed by  IDOC_OUTPUT_DESADV01
    Message no. E0029
    Diagnosis
    IDoc processing has been started for IDoc type DELVRY05. The selected process is of type  and called IDOC_OUTPUT_DESADV01.
    The selected process does not support processing of IDoc type DELVRY05.
    >>
    Is there any function module that i can use  in order to process an IDoc type DELVRY05?
    thanks for your help.
    regards,
    Hermann

    Hi Mohanaselvan
    thanks very much, It's now working !
    regards
    Hermann

  • Function module parameters for L_TO_CREATE_TR

    Hi All,
    Can someone help me out in using the function module 'L_TO_CREATE_TR'.
    What are the necessary import and export parameters along with the table parameters?
    If i want to pass IT_TRITE (table) as export parameters, what are the requisite fields that should be populated inthat table structure?
    Kindly help me out.
    Regards,
    Mainak

    Hi Mainak,
    This is the ABAP and the FM-call:
    data LT_TRITE type L03B_TRITE_T.
    data WA_TRITE like line of LT_TRITE.
    data GV_STORED like VBAPF-QMENGE.
    clear: LT_TRITE, WA_TRITE, GV_STORED.
    refresh LT_TRITE.
    WA_TRITE-TBPOS = GT_LTBP-TBPOS.
    WA_TRITE-ANFME = GT_LTBP-MENGE.
    WA_TRITE-ALTME = GT_LTBP-MEINS.
    WA_TRITE-LETYP = GT_MARA-VHART(3). "3-character storageunittype
    concatenate '000000000000' LTAP-NLENR+10(8) into WA_TRITE-NLENR.
    "FM L_TO_CREATE_TR wants 20 characters
    if GV_DIR = 'N'.
    WA_TRITE-NLTYP = '120'.
    WA_TRITE-NLPLA = 'OVERDRACHT'.
    else.
    WA_TRITE-NLTYP = P_NLTYP.
    WA_TRITE-NLPLA = P_NLPLA.
    endif.
    append WA_TRITE to LT_TRITE.
    TO aanleggen
    clear GT_LTAP_VB.
    refresh GT_LTAP_VB.
    call function 'L_TO_CREATE_TR'
    exporting
    I_LGNUM = GC_LGNUM_011 "LGNUM is '011' in my case
    I_TBNUM = GT_LTBP-TBNUM
    IT_TRITE = LT_TRITE
    importing
    e_tanum = gv_tanum
    tables
    T_LTAP_VB = GT_LTAP_VB
    exceptions
    FOREIGN_LOCK = 1
    QM_RELEVANT = 2
    TR_COMPLETED = 3
    XFELD_WRONG = 4
    LDEST_WRONG = 5
    DRUKZ_WRONG = 6
    TR_WRONG = 7
    SQUIT_FORBIDDEN = 8
    NO_TO_CREATED = 9
    UPDATE_WITHOUT_COMMIT = 10
    NO_AUTHORITY = 11
    PREALLOCATED_STOCK = 12
    PARTIAL_TRANSFER_REQ_FORBIDDEN = 13
    INPUT_ERROR = 14
    others = 15.
    if SY-SUBRC <> 0.
    commit work."See FM L_TO_CREATE_TR docu: commit work is needed
    perform MELDT_DE_FOUT using SY-MSGID SY-MSGTY SY-MSGNO
    SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    else.
    <b>plz reward points if helpful or if it solves ur query.</b>
    Thanks
    Chinmay

  • Accessing function module parameters dynamically ?

    Hello,
    I´m searching for a possibility to access the parameters of a function module dynamically. I.e. I do not know how many parameters a function has, if it is import/export, or the data type.
    Is there a possibility to access (maybe an ABAP-internal) table with these informations? (At runtime within the function module itself)?
    Thany you for your help,
    best regards,
    Stefan

    Use the function module RPY_FUNCTIONMODULE_READ_NEW to read all of the metadata for a funciton module, it returns internal tables for all parameters of the function module interface.
    Regards,
    RIch Heilman

  • Function module parameters mapping

    Hi Expert,
    We are working on a  upgradation tool in which i have to repace the obsolete function module "HELP_VALUES_GET_WITH_CHECKTAB
    " by "F4IF_FIELD_VALUE_REQUEST
    ". I am not sure about the functionalities of these function modules as i have never used it. Can anyone please help me  by providing some information abt  these FMs. Also i need to do the mapping of parameters of old and new function module. So please provide the details of mapping also. Any pointers on this will be highly appreciated.
    Thanks & Regards,
    P Sharma
    Moderator message : Duplicate post locked.  Read forum rules before posting.
    Edited by: Vinod Kumar on Jul 8, 2011 9:55 AM

    please check the below link.
    http://wiki.sdn.sap.com/wiki/display/ERP6/FMHELP_VALUES_GET_WITH_TABLEobsoleteReplacewith+F4IF_INT_TABLE_VALUE_REQUEST
    Edited by: SAP2011 on Jul 8, 2011 4:17 AM

  • Billing type in BAPI_SALESORDER_CREATEFROMDAT2 function Module

    Hi,
    Am creating sales orders through my program using the Function Module "BAPI_SALESORDER_CREATEFROMDAT2".
    I have data(fields) for which i have to create a Sales orders.
    I have mapped all the fields to the structures in the FM except Billing Type, I couldn't find where to map this "billing type" field in the Function Module.
    I want to know into which structure's field in the above FM should this Billing type to be mapped.
    Thanks,
    Adithya M.

    Why do you need to pass the Billing Type when you are creating the Sales Order? Only Sales order type is required in the sales order creation.
    Based on the configuration maintained in the sales order, if future, system will create the specific type of delivery and Specific type of Billing document.
    Regards,
    Naimesh Patel

  • Retrieving of Function Module parameters dynamically

    There is a function module with import and export parameters, I need to pick up the complete structure of the Header Data using a select statement.
    ex: Function Module with import paremeters I1, I2 ..... table parameters t1, t2 .....
    Select from 'Z' table into var .....
    result of this select query is var = 'I1'.
    now there is a macro swc_set_element
    1st parameter = itab
    2nd parameter = var
    now i need to generate 3rd parameter 'I1' dynamically which is an import parameter.
    Edited by: Gaurang Gujar on May 2, 2011 8:04 AM

    Hi.,
    Using Class CL_FB_FUNCTION_UTILITY u can get the Function Module Details.,
    Check this Wiki.,  [Extracting FM details using Class|http://wiki.sdn.sap.com/wiki/display/ABAP/ExtractingFunctionModuleDetailsusingClass-+CL_FB_FUNCTION_UTILITY]
    Also Check these Function Modules:
    FUPARAREF
    FUPARAREF_ENHA " Parameters of Function Modules
    Hope this helps u.,
    Thanks & Regards
    Kiran

  • Table with type ANY in function module

    Hi all
    I want to use a function module in different programs. I want to pass always a table and in a string the name of the structure, so that I can access the data with ASSIGN and the passed structure name.
    For a structure I can use the type ANY, but if I want to use a table in a function module, I need to define a table type.
    Is there a way to define a tabletype with the type ANY? A Workaround would be fine too.
    Thanks and best regards!
    Christian

    Hi Christian,
    ANY TABLE is used to type a parameter, or field symbol, that can be a table of any type or structure.
    ANY is used to type a parameter, or field symbol, that can be any type. You can't, however, use any table operations on a parameter/field-symbol typed as ANY. For that, you have to use ANY TABLE.
    The same applies to ANY. You can pass to the method a data object, without specifying its type (i.e, in dynamic programs).
    Suppose that I need to split a line into a table, but I don't know the structure of this line:
    I have a method:
    codeMETHOD split_line_in_table IMPORTING im_line TYPE ANY
    EXPORTING ex_table TYPE ANY TABLE.
    [/code]
    codeMETHOD split_line_in_table.
    SPLIT im_line AT separator INTO TABLE ex_table.
    ENDMETHOD.[/code]
    Now, i can pass this method a line of ANY structure and get a table without specifying its structure.
    cheers,
    Hema.

  • Trigger Idoc by using the Output type in Z function module

    My requirement is when I run Z function module then  Idoc should be send which is configured in Output Type.
    Means when ever i run the Functional module that Output type should be triggered.?
    Does any one have solution??

    Hi,
    Remove the Material Class from Importing Tab and Place the same under Tables Parameter.
    Regards,
    SRinivas

  • Function module parameters declare BOR Object

    I dont know if this is even logical...
    I need to create a function module which will be used in my  program..
    Can I create an object of BOR object type say 'Sales Order'  and pass it as an export parameter in Function Module..
    i.e i will pass the obj key and obj type as import..
    I want to instantiate that Sales Order.. and pass the whole Sales oRder as export/tables  parameter..
    I know swc_object_create is supposed to create an object but as i can see it only has the handle.. and it is of type swc_object..
    But i want to export  the whole Instance .. so that i can call the methods of the object  in my original program..
    Regards,
    krishna

    Hi Ravi ,
    I simplified my requirement but my actual requirement is with workflows...
    I have a scenario in workflow where,
    1.Activity step to fill internal table with sales order numbers
    2.loop at sales order numbers internal table
    3.Activity Step to Instantiate  based on order numbers
    4. Activity Step to Edit these sales orders
    5.end the loop
    For the above logic in workflows i have separate Activity step for instantiation..What I am thinking of is to instantiate the sales orders and fill the instances in the internal table in Step 1 instead of just order numbers..In the BOR method/F.M  of Step 1 I need to export the Instance of the Sales Orders (this is my actual question/problem, how do i instantiate while coding??swc_object_create, creates only a ref to object ...If I am able to create the object what should the type be in export /tables parameter)
    This way i can remove the loop and offer parallel processing (from miscellaneous tab in activity step) and send multiple Edit workitems to user  at Once instead of one after the other..
    Please let me also know how you would handle the above situation, i am very new to workflows and BOR.

  • Function module parameters

    using the function module WDY_EXECUTE_IN_PLACE
    to call web dynpro what is the parameter internalmode and  how is it used?
    thanks

    Hi,
    This function module is used to execute the Web Dynpro Application manually. Well, this parameter is used to set the execution type, if the INTERNAL MODE is 'X' then the application executes in SAP GUI itself.If not set, then the application is executed in a browser.
    Hope this helps.
    Regards
    Raja Sekhar

  • Issue with the RFC function module - parameters

    Hi,
        When i am creating RFC enabled function module, it was throwing an error like <b>'Reference parameters are not allowed with RFC'.</b>. I am implementing the test scenario to create BAPI, for that i have created table with 2 fields. My main intension is through RFC enabled function module planning to update the ztable.
       When i was creating RFC enabled function module, it was giving error. I remembered that  i need to use new structure when i create RFC enabled function module, so even i created structure also with the same fields of table fields.
       can you please let me know the solution for this.
    Thanks
    jaya

    Hi Ferry,
        Your solution is perfect. can you please explain the below information...
    Call by value                                                                               
    You pass the parameter with values. This means that the parameter     
         contents are copied both when the parameter is passed and when it is  
         transferred back to the calling parameter. For structures that contain
         tables, performance may be reduced considerably. Therefore, you should
         not do this.                                                                               
    I created the parameters with reference to table-fields, what do you mean by 'Call by value'check box usage there.
    Is it mean ...if i change the contents of the field in FM will it pass back to the structure which i refered to this parameter, in this case its table-field.
    Thanks
    jaya

  • Table parameter Types for this Function module

    I am using K_HIERARCHY_TABLES_READ to get the profit centers for a given profit center group.
    I have the following declarations for the parameters of this FM:
    TYPE-POOLS: gseth.
    Declarations for Profit Center Group
    DATA: g_pcgrp     TYPE rgsbs-class,
          g_setid     TYPE rgsbs-setnr,
          g_info      TYPE grphinfo,
          g_overwrite TYPE sy-datar.
    DATA:
          i_nodes      TYPE STANDARD TABLE OF gseth_node_tab,
          i_values     TYPE STANDARD TABLE OF gseth_val_tab,
          i_masterdata TYPE STANDARD TABLE OF grpmdline.
    When this is run, its taking me into a dump and it says:
    The reason for the exception is:
    The system tried to pass internal table "I_NODES" to the formal
    parameter "T_NODES", but a type conflict occurred between the
    formal and the actual parameter.
    Pl help me to correct this dump and error.
    Thanks
    Kiran

    DATA:
    i_nodes TYPE STANDARD TABLE OF gseth_node_tab,
    i_values TYPE STANDARD TABLE OF gseth_val_tab,
    i_masterdata TYPE STANDARD TABLE OF grpmdline.
    change your declarations
    to the below...
    DATA:
    i_nodes TYPE gseth_node_tab,
    i_values TYPE gseth_val_tab,
    i_masterdata TYPE STANDARD TABLE OF grpmdline.

  • Virtual InfoCube with Services - function module parameters documentation ?

    Hello,
    I have been trying to use a Virtual Infocube with Services.
    I have seen most of the posts in SDN, and read the documentation in http://help.sap.com/saphelp_nw04/helpdata/en/8d/2b4e3cb7f4d83ee10000000a114084/frameset.htm
    I did not manage to find a precise description of the import 
    parameters of the Variant 2.
    In particular, what is the meaning of the
    i_tx_rangetab TYPE rsdri_tx_rangetab parameter. I read in the code of RS_BCT_FIGL_DATA_GET that it has to do with query columns. In the tests I did this table is alway empty.
    Also, i_th_sfc gives you the list of characteristics used in the query. But it does not inform you on wether these are in the 'rows' 'free characteristics' or 'filter'. Is there a way of knowing that?
    Claudio Ciardelli

    Hi Claudio,
    I never implemented Virtual InfoCube with services with a FM, but I know there is a couple of How To Documents about named:
    - How to Reporting from External Data via Virtual InfoProvider
    -How to Implement a Virtual InfoCube with Services
    both with some code samples: did you read it?
    Hope it helps
    GFV

Maybe you are looking for

  • How do I create a hyperlink to a specific section of a flash website?

    Ok, I have no experience coding in flash, I just want to create links to specific parts of a flash website (website that were created by other people, not that I am building). In other words, I just want to create the hyperlink that will open a certa

  • Error in Seeburger Message Monitoring

    Hi , I m using Seeburger as Sender R/3 System.and the receiver is Xi.as an idoc file. I m getting error in seeburger message monitoring with status as "Could not send ansynchrone MDN to partner - url not set!". can anybody tell me whats the reason be

  • LabVIEW Positions in Bangalore

    Bangalore division of a US based Select Integrator is seeking talented Systems Engineers to be responsible for technical execution of successful projects. This is a very fast paced team with close customer contact and strong career development opport

  • Commit on one application module also commits the other

    Jdev 11.1.1.4 I have a fusion ADF application where I have defined two Data Controls. One is called AppModuleDatacontrol and the other AppModuleWSDataControl. I do this in order to be able to commit DML made on one Data Control independently of the o

  • How do I get the AFP.pkg to install the Flash Player?

    Hi, I have iBook G4 ppc OS 10.4.11 I have downloaded Adobe Flash Player.pkg v. 10. When I click it I get "Easy Install on "Macintosh HD". I highlight my HD. I close all browsers. I click "Upgrade" for a basic Installation. The installation bar runs q