WDY_EXECUTE_IN_PLACE Parameters table

Hi experts,
i'm trying to call a webDynpro from SAPGui with function wdy_execute_in_place. This already works. But now i want to fill some fields within my webdynpro by calling it.
in special i have built a selection screen with wdr_select_options and a ViewContainerUIElement. There are 3 fields: EBELN EBELP EXTROW. Now i want that these Fields (all have no extensions and no intervals) with content from SAPGUI.
i've tried to fill the importing parameter PARAMETER, which is a table with the following expressions:
ls_parameter-name = 'EBELN'.
ls_parameter-value = '4512345678'.
APPEND ls_parameter to lt_parameter.
Do i have to give the name of the view and the uielement to fill? and how do i have to write that?
Can anybody help me with that?

Hi,
Your parameters are passed to web dynpro application and those needs to be retrieved in event handler method of DEFAULT plug of your window in WD component as below
Now, by using url parameters, you can set value of your selection screen by using method SET_RANGE_TABLE_OF_SEL_FIELD( for selection field ), SET_VALUE_OF_PARAMETER_FIELD ( for parameter field )
Hope this helps you.
Regards,
Rama

Similar Messages

  • Preparedstatement - parameterizing table name

    public Vector getTableColumns(String tblName) {         loadDriver();         t.removeAllColumns();         try {             pstmt = conn.prepareStatement("select * from ? where rownum < 1");             pstmt.setString(1, tblName);             rs = pstmt.executeQuery();             rsMetaData = rs.getMetaData();             numberOfColumns = rsMetaData.getColumnCount(); //get the number of columns             for (int i = 0; i < numberOfColumns; i++) {                 // get the designated column's table name.                 t.setColumn(rsMetaData.getColumnName(i + 1)); //get the columns and add them to Vector             }             conn.close();         } catch (SQLException e) {             e.printStackTrace();         } finally {             closeConnection(conn);         }         return t.getColumn(); //return the array of the column names     }
    it says invalid table name
    i tried hardcoding the table name inside and it works though

    OnlyForJava wrote:
    plz suggest another wayAs coded in your first post, presuming that you are not in fact trying to do something from the other thread...
    There is no other way.
    Parameterized types can not be used to represent DDL entities - they can only represent data.

  • User Parameters Table

    Hi All,
    I want to know the tables where the User Parameters are stored. By User parameter, i mean the The User Profile - Parameter ID & Value.
    Any pointers would be helpful.
    Thanks in advance,
    Best regards,
    Prashant

    hi
    good
    USR01 User master record (runtime data)
    USR02 Logon data
    USR03 User address data
    USR05 User Master Parameter ID
    USR12 User master authorization values
    thanks
    mrutyun

  • Invalid directory path due to missing pathe under parameters table

    I have created directory xyz & also data being appeared under the privilege table.
    But problem is that how that directory path would be added through command in parameter table as mentioned.
      select *  from v$parameter where name = 'utl_file_dir';
     

    Mentioned stepts.
    --created directory
    create directory XX_HRMS as '/apps/hrms'
    --check wheather directory has been created or not
    SELECT * FROM dba_directories where directory_name = 'XX_HRMS'
    OWNER  DIRECTORY_NAME     DIRECTORY_PATH
    1     SYS     XX_HRMS     /apps/hrms
    --check privilages
    SELECT *   FROM DBA_tab_privs WHERE table_name = 'XX_HRMS'
       GRANTEE  OWNER  TABLE_NAME  GRANTOR  PRIVILEGE  GRANTABLE  HIERARCHY
    1  SYSTEM  SYS  XX_HRMS  SYS  READ  YES  NO
    2  SYSTEM     SYS     XX_HRMS     SYS     WRITE     YES     NO
    3     APPS     SYS     XX_HRMS     SYSTEM     READ     NO     NO
    4     APPS     SYS     XX_HRMS     SYSTEM     WRITE     NO     NO
    --- using this directory
    declare
    output_file utl_file.file_type;
    v_file_name  varchar2(100) := 'abc.tx';
      begin         
       output_file := utl_file.fopen ('/apps/hrms',v_file_name, 'W');
            utl_file.put_line (output_file,' insert my new line ');   
           UTL_FILE.FCLOSE(output_file);
    END;
    --- when i run of above pl-script then system raise an error.
    ORA-29280: invalid directory path Pls guide me.
    thanks

  • Updating icx parameters table

    Hi,
    As a part of iProcurement implementation we need to update
    icx_parameters table to be able to view some screens.
    I had the script that I used once , but I lost it now, Can
    anyone pls send me the script pls?
    Any help would be appriciated.
    Thanks
    Shital

    My issue got resolved:
    I am not using search criteria.
    When I want to refresh the table (suppose on a click of button), call the following:
    DCBindingContainer dcBindings = BindingContext.getCurrent().findBindingContainer("oracle_rme_view_SearchCertificationsPageDef");
    // the page def id found from DataBindings.cpx for the specific page. Alternate would be // DCBindingContainer dcBindings = (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
    DCIteratorBinding iterBind1 = (DCIteratorBinding)dcBindings.get("searchResultsIterator");
    iterBind1.executeQuery();
    How ever, stuck with small issue here, when the button is clicked from a different page than where the table exists, it does not refresh the table (How ever, the same work when navigated for the first time and does not after wards).

  • RFC Lookup - BAPI-TABLE Parameters problem

    Hello All,
    I had a scenario where i need to export parameters and am supposed to get import parameters from BAPI between source and target structures.
    like -
    source --> BAPI execution = result --> target
    We had succeeded in getting those but the only problem is with TABLE parameters in that BAPI.
    How can we achieve it.
    Faster reply would be appreciated.
    Thanks & regards
    Reddy

    Hi VJ,
    Its not a simple source-target mapping .
    For Ex :
    Source-Bapi-Idoc
    Source will send some parameters to BAPI and bapi will execute it and respond with values in table parameter of the bapi and result would be assigned to idoc-field.
    For this i am using RFC Look up with sample code as :
    String rfcxml ="<ns0:Z_BAPI xmlns:ns0=\"urn:sap-com:document:sap:rfc:functions\">" +
    "     <A>" + A + "</A>" +       --- Export parameters
    "     <B>" + B + "</B>" +       --- Export parameters
    //"                       <TABLE><FIELD1>" + FIELD2 + "</FIELD1></TABLE>" +
    //"                       <TABLE><FIELD2>" + FIELD2 + "</FIELD2></TABLE>" +
    //"                       <TABLE><FIELD3>" + KDMAT+ "</FIELD3></TABLE>" +
    //          "<FIELD1>" + FIELD1 + "</FIELD1>" +
    "</ns0:Z_BAPI> "  ;
    Passing A & B as export parameters and getting TABLE-FIELD1&2&3 as response.
    I hope some problem in the syntax.
    Regards,
    HP

  • Fetch data from table(ET_) which is exporting parameter of function module

    Hi,
    I m new to ABAP programming.
    I have to develop a smartform that has to be filled in with fields from few tables.
    These tables have the naming convention ET_<XXX> (i.e. exporting parameter of function module).
    I m not able to directly view its contents in se11 or use select query for it.
    I have a report program which i can execute to view these parameter names.
    Now, how do i fetch data from these parameters/tables and pass it from my driver program to smartform??
    Someone pls guide me...
    Thank You.

    Hi,
    I have done that using Field-Symbols.
    Thanks,
    Preetha

  • Help needed for report on tables vbak and vbap

    Hello,
    I needed help in one of my work issues, this is my first project and Iam still learning. kindly help.
    I was asked to take erdat,vbeln,posnr from selection screen and compare it with the data already in tables vbap,vbak. If the data
    already exists and exception needs to be raised saying that the 'data exists',but if the data is not present in the tables the
    tables have to be updated. This has to be done using function module only.
    Then I have to write a REPORT calling the above function module and finally displaying the number of records updated and the
    list of them.
    I have started writing a function module:
    FUNCTION z_tableupdate.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(DATE) LIKE  VBAK-ERDAT DEFAULT SY-DATUM
    *"     VALUE(SALESORDERNO) LIKE  VBAK-VBELN
    *"     VALUE(ITEMNO) LIKE  VBAP-POSNR
    *"  EXPORTING
    *"     VALUE(EX_VBAP) LIKE  VBAP STRUCTURE  VBAP
    *"     VALUE(SYS) LIKE  SY-SYSID
    *"     VALUE(EX_VBAK) LIKE  VBAK STRUCTURE  VBAK
    *"  EXCEPTIONS
    *"      DATA_UPDATED
    *"      DATA_EXISTS
      SELECT * FROM vbak INTO vbak_wa WHERE erdat = date
                                        AND vbeln = salesorderno.
      ENDSELECT.
      SELECT * FROM vbap INTO vbap_wa WHERE posnr = itemno.
      ENDSELECT.
      IF sy-subrc EQ 0.
        ex_vbap = vbap_wa.
        ex_vbak = vbak_wa.
      ELSE.
        RAISE data_exists.
      ENDIF.
      sys = sy-sysid.
    ENDFUNCTION.
    How is the above code for function module, will this work??
    Now can I write a report to call the above function module and update the record?? if so, how to update ??? please help...Lots of thanks in advance.

    Hi
    Welcome to SDN forum
    Whay can't you write a simple report in SE38.
    why you are using Fun module
    Nothing wrong in it.
    But first become perfetc in reports in SE38 and then do using the fun modules
    write a simple select statement like
    SELECT AVBELN AERDAT BPOSNR BMATNR
    INTO TABLE ITAB
    FROM VBAK AS A JOIN VBAP ON
    AVBELN = BVBELN
    WHERE A~VBELN  IN  S_VBELN AND
                 A~ERDAT  IN  S_ERDAT AND
                 B~POSNR IN S_POSNR.
    IF SY-SUBRC <> O.
      WRITE: / 'No data found'.
    ENDIF.
    First write this in SE38 by defining a proper selection screen and internal tables
    then do as fun module
    see the doc for fun module
    Function Modules;
    Check this matter.
    Function Modules are Global ABAP programs created by SAP for reusable purpose.they have IMPORT,EXPORT and TABLE parameters, and EXCEPTIONS to through when error occurs.
    You can create them from TCode SE37.
    Go through the following doc:
    Function modules are cross-program, reusable procedures that are organized into function groups, and whose functions are implemented between the statements FUNCTION and ENDFUNCTION. Function modules and their interfaces are created in the Function Builder.
    Function Module Interfaces
    The parameter interface of a function module is defined in the Function Builder. It includes the definition of interface parameters and the specification of exceptions that can be triggered by a function module. The Function Builder automatically generates comment lines below the FUNCTION statement in the source code of the function module, which represent the interface of the function module with the following syntax:
    Syntax
    ... [IMPORTING parameters]
    [EXPORTING parameters]
    [CHANGING parameters]
    [TABLES table_parameters]
    [{RAISING|EXCEPTIONS} exc1 exc2 ...]
    The syntax and semantics of IMPORTING, EXPORTING, CHANGING, RAISING, and EXCEPTIONS mainly correspond to the definition of method interfaces with [CLASS-]METHODS. The additional option of defining table parameters using TABLES is obsolete.
    Interface parameters
    The interface parameters are defined on the relevant tab pages in the Function Builder.
    IMPORTING parameters are input parameters. When the function module is called, a suitable actual parameter must be specified for every non-optional input parameter. The content of the actual parameter is passed to the input parameter when the call is made. The content of an input parameter for which 'pass by reference' is defined cannot be changed in the function module.
    EXPORTING parameters are output parameters. When the function module is called, a suitable actual parameter can be specified for every output parameter. The content of an output parameter that is defined for 'pass by value' is transferred to the actual parameter if the function module is completed without errors. An output parameter that is defined for pass by reference is not initialized when the function module is called.
    CHANGING parameters are input and output parameters. When the function module is called, a suitable actual parameter must be specified for every non-optional input or output parameter. When the function module is called, the content of the actual parameter is passed to the input/output parameter, and when the function module is completed, the content of the input/output parameter is passed to the actual parameter.
    TABLES parameters are table parameters. Table parameters are obsolete CHANGING parameters that are typed as standard tables with a header line. If an internal table without a header line or a table body is passed as an actual parameter to a formal parameter of this type, an empty local header line is generated in the function module. If an internal table with a header line is used as an actual parameter, both the table body and the header line are passed to the function module. Pass by value is not possible in formal parameters defined using TABLES. Formal parameters defined with TABLES can be replaced by formal parameters defined with CHANGING. A local work area can be created for the internal table in the function module by using the addition LIKE LINE OF itab of the DATA statement.
    Exceptions
    The exception of a function module are defined on the Exceptions tab page in the Function Builder. Here you can select exception classes to define whether class-based exceptions are declared or non-class-based exception are defined. Class-based exceptions are represented in the above syntax by RAISING, and non-class-based exceptions are represented by EXCEPTIONS.
    The addition RAISING is used to declare class-based exceptions that can be propagated from the function module to the caller. Exceptions in the categories CX_STATIC_CHECK and CX_DYNAMIC_CHECK must be explicitly declared, otherwise a propagation can lead to an interface violation. A violation of the interface leads to the treatable exception CX_SY_NO_HANDLER. Exceptions of the category CX_NO_CHECK are implicitly always declared. The declaration of exceptions of the category CX_STATIC_CHECK is statically checked in the syntax check. For exceptions of the category CX_DYNAMIC_CHECK, the check is not performed until runtime. In a function module in which class-based exceptions are declared with the RAISING addition, the statement CATCH SYSTEM-EXCEPTIONS cannot be used. Instead, the relevant treatable exceptions should be handled in a TRY control structure.
    The addition EXCEPTIONS is used to define a list of non-class-based exceptions that can be triggered in the function module using the statements RAISE or MESSAGE RAISING. Exceptions defined in this way - as with formal parameters - are bound to the function module and cannot be propagated. If an exception of this type is triggered in a function module, and no return value has been assigned to it with the homonymous addition EXCEPTIONS of the CALL FUNCTION statement when the call was made, this leads to a runtime error.
    Note
    For new developments after release 6.10, SAP recommends that you work with class-based exceptions that are independent of the function module.
    RFC is a technology which is used to access a functions (Modules) from
    the remote systems.
    If a function module is set as remote enabled which can be access from
    the remote system via RFC.Eg: U can access the Remote enabled function modules in ur VB,Webdynpro,Java,Visual composer program.
    A function module can be set as remote enabled by SE37->Go to ur FM->click the option Button "remote enabled".
    But Normal function modules can not accessd from the remote system.
    Good Example for RFC enabled function module is : BAPI(Business Application Programming Interface)
    Note: All BAPIs are Remote enabled but not all remote enabled function modules are BAPI.
    CALLING A FUNCTION MODULE:
    1)In U ABAP Editor --> Click "Patter" ---> Selection Option Button "Call Function"
    --> Write the Corresponding FM name --> Hit Enter
    2)The appropriate import ,export Parameters will be displayed in ur editor
    3)Pass the Values Here.
    Also check these links.
    http://www.geocities.com/victorav15/sapr3/abapfun.html
    Check this link:
    http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db988735c111d1829f0000e829fbfe/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/ef/d94b78ebf811d295b100a0c94260a5/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/43/41341147041806e10000000a1553f6/frameset.htm
    Check this link:
    http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db988735c111d1829f0000e829fbfe/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/ef/d94b78ebf811d295b100a0c94260a5/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/43/41341147041806e10000000a1553f6/frameset.htm
    See the following links:
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/26/64f623fa8911d386e70000e82011b8/content.htm
    Regards
    Anji

  • SRM-MDM Catalogue Search UI - Qualified table search

    Hi,
    We are having the following situation:
    - We have a catalogue of articles
    - We have to tie an article to a location, in addition to a location-specific parameter.
    - Exampe:
    Article A is tied to location A, parameter A
    Article B is tied to location B, parameter B
    Article C is tied to location A, parameter B
    - The way to solve this in MDM is to use the qualified table. I have created one where:
    Location = non-qualifier
    parameter = qualifier
    I want to make this searchable in the SRM-MDM search UI.
    The user should be able to choose one Location, and then one parameter tied to that Location, to view relevant articles.
    This is no problem using SAP Portal with MDM. But how can we realise this using SRM-MDM search UI?
    I have tried, but can only get a drop down or text search on the non-qualifier field.
    Can anyone please help? Is this even possible?
    KR;
    Thomas

    Hi Thomas,
    Is there any possibilities to configure/add code to the search UI, or is this completely locked for customization/altering through code? Unfortunately, I feel it is standard and we can not customize it.
    There is no issue in your design but if your location as well as parameter has certain(limited) number of values only. You can create location field in MDM Main table which is lookup to Locations Flat table and similarly for Parameter field lookup to Parameters table rather than using Qualified table. As you can set lookup/Text field search only, so you can set these two fields in your search criteria. where first you search for Location say US it will search records with US location and when you further give search according to parameter it will further filter(navigate) records based on both Location and parameter, just a thought came which i feel to share with you, try it if it helps you.
    Regards,
    Mandeep Saini

  • How to create function module to update z tables?

    Hi,
    I am new to ABAP. I checked the forum but did not find relevant solutions.
    I have 2 z tables - ZFLIGHT and ZCUSTOMER. I have a few entries in each table.
    I want to write a report to update the entries in the table using function modules. For that I have created a function module - zflight_fm and also a function group- zflight_fg and assigned the function group to the Fm. I do not know how to proceed further, what to put as import, export parameters, tables, changing etc. Further I want exceptions to handle the successful update of the entries.
    Thanks and regards,
    Smruthi

    Steps:
    1) Changing --->a) Zflight TYPE ZFLIGHT(DDIC Ref) OR  Zflight TYPE  ANY TABLE
                           b) ZCustomer TYPE ZFLIGHT(DDIC Ref) OR  ZCustomer TYPE  ANY TABLE
    2) Execptions:
         a) Upload_failed_Flight
         b) Upload_Failed_Customer
    3) Exporting ---> a) Information what rows are uploaded
    Source Code:
    Insert Zflight from Zflight(changing parameter).
    If insert failed
    RAISE  Upload_failed_Flight.
    endif.
    Insert ZCustomer from ZCustomer(changing parameter).
    If insert failed
    RAISE  Upload_failed_Customer.
    endif.
    Regards,
    Gurpreet

  • Lock object for KONV table/Cluster table ??

    Hi All,
    Is it possible to set Lock/Enqueue cluster tables or in my case table:KONV (KNUMV field) ?.
    OSS provided some programs without locks so was hoping if I could add before performing data manipulation.
    Regards,
    Neeth

    Hi Nameeth,
    you can use generic lock object E_TABLE with function modules ENQUEUE_E_TABLE, DEQUEUE_E_TABLE for locking and unlocking with parameters table name and key field.
    Regards,
    Satya

  • What are all the tables used for this report ? please reply

    hai
    i have practcing reports,
    so any one give me the name of the tables used for the below report
    <b>Created report for invoice details, shipping details and partner function.</b>
    thanks in advance.
    by
    ashok

    Hi Ashok,
      I am sending you the code which will display tables present in SAP with the description and jump to datadic or SE16 by selecting plus F2 or F8.
    REPORT ZZBGS044 MESSAGE-ID Z1 LINE-COUNT 65 LINE-SIZE 132
                    NO STANDARD PAGE HEADING.
    Description: This program list all tables in        regards to the   *
                 selection criteria.                                     *
    Customizing: You need not to make any customizing to use this program*
    Change of    You only have to check that tables, functions and       *
    release:     includes till exists. Bedst just to check and run the   *
                 program.                                                *
    Programmer:  Benny G. Sørensen                                       *
    Date:        July 1995                                               *
    SAP R/3      2.2F                                                    *
    Corrections----
    Date        Userid     Correction                                    *
    xx-xx-xxxx  xxxxxxxxx  xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx *
    TABLES: DD02V                "SAP tables view
    DATA: BEGIN OF DYNTAB OCCURS 2000.
            INCLUDE STRUCTURE BDCDATA.
    DATA: END OF DYNTAB.
    DATA: BEGIN OF TABLES OCCURS 100.
            INCLUDE STRUCTURE DD02V.
    DATA: END OF TABLES.
    DATA: L        TYPE I,
          REPL(30) TYPE C VALUE '????????????????????????????'.
    FIELD-SYMBOLS:
    PARAMETERS:
    TABLE(30) TYPE C,
    TITLE(74) TYPE C LOWER CASE DEFAULT ' ',
    DOWNLOAD(1) TYPE C DEFAULT ' ',
    FILENAME(65) TYPE C DEFAULT 'c:SAPDOC?',
    EXCEPT(30) TYPE C DEFAULT ' '.
    START-OF-SELECTION.
    IF TABLE = ''.
    TABLE = '*' .
    ENDIF.
    IF TITLE = ''.
    TITLE = '*' .
    ENDIF.
    TRANSLATE TABLE USING '*%'.
    TRANSLATE TITLE USING '*%'.
    CONDENSE EXCEPT NO-GAPS.
    L = STRLEN( EXCEPT ).
    IF L > 0.
    ASSIGN REPL(L) TO
    ENDIF.
    SELECT * FROM DD02V INTO TABLES
    WHERE DDLANGUAGE = SY-LANGU
    AND TABNAME LIKE TABLE
    AND DDTEXT LIKE TITLE.
    HIDE DD02V-TABNAME.
    IF EXCEPT NE ''.
    REPLACE EXCEPT LENGTH L WITH
    INTO TABLES-TABNAME.
    ENDIF.
    TRANSLATE TABLE USING '% '.
    CONDENSE TABLE NO-GAPS.
    IF TABLES-TABNAME CS TABLE.
    WRITE:/ TABLES-TABNAME, ' ', TABLES-DDTEXT.
    APPEND TABLES.
    ENDIF.
    ENDSELECT.
    IF DOWNLOAD NE ''.
    CALL FUNCTION 'WS_DOWNLOAD'
    EXPORTING
    FILENAME = FILENAME
    FILETYPE = 'WK1' "ASC, WK1, DBF, DAT, bin
    TABLES
    DATA_TAB = TABLES.
    ENDIF.
    AT LINE-SELECTION.
    SET PARAMETER ID 'DOB' FIELD SY-LISEL(30) .
    CALL TRANSACTION 'SE12' AND SKIP FIRST SCREEN.
    AT PF8.
    CHECK SY-LISEL <>
      SET PARAMETER ID 'DTB' FIELD SY-LISEL(10) .
      REFRESH  DYNTAB.
      PERFORM DYNPRO USING:
         'X'  'SAPMSTAZ'     '0100'        "Selection screen
        ,' '  'DD02V-TABNAME'  SY-LISEL(10).
      CALL TRANSACTION 'SE16' USING DYNTAB MODE 'A' .
    FORM DYNPRO USING DYNBEGIN NAME VALUE.
      IF DYNBEGIN = 'X'.
        CLEAR DYNTAB.
        MOVE :  NAME TO DYNTAB-PROGRAM,
                VALUE TO DYNTAB-DYNPRO,
                DYNBEGIN TO DYNTAB-DYNBEGIN.
        APPEND DYNTAB.
      ELSE.
        CLEAR DYNTAB.
        MOVE:  NAME TO DYNTAB-FNAM,
               VALUE TO DYNTAB-FVAL.
        APPEND DYNTAB.
      ENDIF.
    ENDFORM.
    Regards,
    Azaz Ali.

  • Program to upload and download table content

    Hi,
    I need to create a program which should upload and download table content from PC and to PC.
    How can i develop this program..Should i use BDC or any function module?
    Ezhil.

    The 2 program requested.....
    Program to Download
    REPORT ztable_download.
    PARAMETERS: table LIKE dd02d-tabname,
                                file(50) LOWER CASE.
    DATA: code(72) OCCURS 10,
                w_code(72),
                prog(8),
                msg(120),
                lin(3),
                wrd(10),
                off(3).
    DATA: BEGIN OF rectest,
          tprec(1) VALUE '0',
          nometab(16),
          utente(20),
          data(10),
          ora(8),
    END OF rectest.
    DATA: BEGIN OF recdett,
          tprec(1) VALUE '1',
          tab LIKE table,
    END OF recdett.
    DATA: BEGIN OF rectot,
        tprec(1) VALUE '2',
        tot(9),
    END OF rectot.
    OPEN DATASET file FOR OUTPUT IN TEXT MODE.
    rectest-nometab = table.
    rectest-utente = sy-uname.
    rectest-data = sy-datum.
    rectest-ora = sy-uzeit.
    TRANSFER rectest TO file.
    APPEND 'PROGRAM SUBPOOL.'  TO code.
    CONCATENATE 'TABLES ' table '.' INTO w_code SEPARATED BY space.
    APPEND w_code TO code.
    APPEND 'FORM DYN1 USING FILE.' TO code.
    CONCATENATE 'SELECT * FROM ' table '.'
    INTO w_code SEPARATED BY space.
    APPEND w_code TO code.
    CONCATENATE 'TRANSFER ' table ' TO FILE.'
    INTO w_code SEPARATED BY space.
    APPEND w_code TO code.
    APPEND 'ENDSELECT.' TO code.
    APPEND 'ENDFORM.' TO code.
    GENERATE SUBROUTINE POOL code NAME prog
    MESSAGE msg LINE lin WORD wrd OFFSET off.
    IF sy-subrc <> 0.
       WRITE: / 'Error during generation in line', lin,
                    / msg,
                    / 'Word:', wrd, 'at offset', off.
    ELSE.
       PERFORM dyn1 IN PROGRAM (prog) USING file.
       WRITE: / 'Esportati ',sy-dbcnt,' records.'.
    ENDIF.
    Program to upload
    REPORT Ztable_upload.
    PARAMETERS: FILE(50) lower case,
                               TEST AS CHECKBOX.
    DATA: CODE(72) OCCURS 10,
                W_CODE(72),
                PROG(8),
                MSG(120),
                LIN(3),
                WRD(10),
                OFF(3).
    DATA: BEGIN OF RECTEST,
          TPREC(1) VALUE '0',
          NOMETAB(16),
          UTENTE(20),
          DATA TYPE D,
          ORA TYPE T,
    END OF RECTEST.
    DATA: BEGIN OF RECTOT,
          TPREC(1) VALUE '2',
          TOT(9),
    END OF RECTOT.
    OPEN DATASET FILE FOR INPUT IN TEXT MODE.
    READ DATASET FILE INTO RECTEST.
    WRITE:/ 'Tabella..:',RECTEST-NOMETAB.
    WRITE:/ 'Utente...:',RECTEST-UTENTE.
    WRITE:/ 'Data.....:',RECTEST-DATA,RECTEST-ORA.
    IF TEST = 'X'.
        APPEND 'PROGRAM SUBPOOL.'  TO CODE.
       CONCATENATE 'TABLES ' RECTEST-NOMETAB '.'
       INTO W_CODE SEPARATED BY SPACE.
      APPEND W_CODE TO CODE.
      APPEND 'FORM DYN1 USING FILE.' TO CODE.
      APPEND 'DATA W_COUNT TYPE P.' TO CODE.
      CONCATENATE 'SELECT * FROM' RECTEST-NOMETAB '.'
      INTO W_CODE SEPARATED BY SPACE.
      APPEND W_CODE TO CODE.
      CONCATENATE 'DELETE' RECTEST-NOMETAB '.'
      INTO W_CODE SEPARATED BY SPACE.
      APPEND W_CODE TO CODE.
      APPEND 'ENDSELECT.' TO CODE.
      APPEND ' DO.' TO CODE.
      CONCATENATE 'READ DATASET FILE INTO' RECTEST-NOMETAB '.'
      INTO W_CODE SEPARATED BY SPACE.
      APPEND W_CODE TO CODE.
      APPEND ' IF SY-SUBRC NE 0.' TO CODE.
      APPEND ' EXIT.' TO CODE.
      APPEND ' ENDIF.' TO CODE.
      CONCATENATE ' INSERT ' RECTEST-NOMETAB '.'
      INTO W_CODE SEPARATED BY SPACE.
      APPEND W_CODE TO CODE.
      APPEND 'ADD 1 TO W_COUNT.' TO CODE.
      APPEND 'ENDDO.' TO CODE.
      APPEND ' write: / ''Importati'' ,W_COUNT, ''records''.' TO CODE.
      APPEND 'ENDFORM.' TO CODE.
      GENERATE SUBROUTINE POOL CODE NAME PROG
      MESSAGE MSG LINE LIN WORD WRD OFFSET OFF.
      IF SY-SUBRC <> 0.
         WRITE: / 'Error during generation in line', LIN,
         / MSG,
         / 'Word:', WRD, 'at offset', OFF.
      ELSE.
         PERFORM DYN1 IN PROGRAM (PROG) USING FILE.
      ENDIF.
    ENDIF.
    Edited by: robcom69 on Feb 23, 2010 2:35 PM

  • PowerPivot and query parameters

    Is there any plans to support parameterized sql queries?If I try to execute query it requests declared parameters by means of form,but I can't check resulting query.Why?It says "Must declare the scalar variable ...". 
    WTF?
    Regards.
    P.S.
    Without parameterizing PowerPivot is useless  IMHO.

    What we decided to do, as this is a glaring oversight is to expose a Parameters table via BDC. The end users can then set the "global parameters" for the site, (like date ranges for a quarter that they want to expose). They are able to make updates directly
    to the parameters then when the data is refreshed we are able to get a filtered view. Not perfect, but certainly better than having to open multiple sheets to reset very similar parameters.
    We did something like this, with the initial settings set to defaults so if the users were to delete the parameters they would simply get this current year. While it isn't 100% wonderful it gets us by, and enables our customer to surface only the data sets
    they are interested in making available. 
    Declare @datestart as datetime
    Declare @dateend as datetime
    Set @datestart='01/01/2013' 
    Set @dateend='01/10/2014'
    select @datestart = value from parameters where name = 'StartDate';
    select @dateend = value from parameters where name = 'EndDate';
    QUERY HERE.

  • Discussion of ideas - passing parameters to a report

    Guys,
    I call a series of reports from my form and each report takes different parameters, these parameters are entered on the form then when the report is launched they are passed to the report. Rather standard and basic stuff.
    However can people suggest how they would envisage the problem of some reports requiring more or less parameters than others? (I can easily send all the parameters and the report just use which ones it needs). But if someone can think of a way in which I could somehow hide the unneccessary text items? Ensuring only the text items which relate to parameters required by the selected report are displayed this would be much appreciated.
    Thanks!

    I totally agree with Ino Laurensse idea of designing tables to store Reports and Reports parameters :
    2 tables is sufficient :
    Tab_Reports : /* Defines all reports */
    Report_Id Varchar2(30) Not Null PK
    Report_Desc Varchar2(255);
    Report_Params /* All parameters associated with the reports */
    Report_Id Varchar2(30) Not Null PK References Tab_Reports (Report_Id)
    Parameter1_Text Varchar2(30) /* Labael of Parameter */
    Parameter1_Type Varchar2(20) /* Type of Parameter- Varchar, Date, Number etc */
    Parameter1_Default Varchar2(255) /* To store any default values */
    Parameter1_Mandatory Varchar2(1) /* Indicates if Parameter value is mandatory or not
    Parameter50_Text Varchar2(30) /* Labael of Parameter */
    Parameter50_Type Varchar2(20) /* Type of Parameter- Varchar, Date, Number etc */
    Parameter50_Default Varchar2(255) /* To store any default values */
    Parameter50_Mandatory Varchar2(1) /* Indicates if Parameter value is mandatory or not
    NOTE :- The maximum Number of parameters to be set up depends upon the application. You
    will be in a better position to decide.
    All you have to do is the following :
    1. Define 2 Blocks within you form based on the above 2 blocks
    2. Query all records from table : Tab_Reports
    3. Double-Click on Report_Id should :
    3a. Pop up a window
    3b. Pop up window block has base table associated with child table : Report_Params
    3c. Report_Param is queried based on Reporet_Id Selected on the table : Tab_Reports
    3d. Use a Non-Database Text Item to enter the Parameter Value in block Report_Params
    NOTE :- You can set up Master-Detail Relation if you want to
    3d. In relavant trigger all you have to do is :
    3d1. Use Set_Item_Property to Non-Db Column to set the column data type, Mandatory and
    Initial Value of the parameter column
    This method, Let ORACLE forms do all validations. You don't have to worry about it.
    4. To Call reports with appropriate Parameters :
    4a. All you have to do is Loop through the Block and use Add_Parameter to the Parameter List
    before using the bult-in to call the report module.
    Whenever a new report is created, all you have to do is :
    1. Create a new entry in table : Tab_Reports
    2. Buld up the associated parameters table : Rep_Params
    -- Shailender Mehta --

Maybe you are looking for

  • Passing arguments in a .py script

    I have a .py script which starts with a "connect()" statement. Whenever I run it, I need to give username, password & server URL manually. But I want to make this script non-interactive. At the same time, I don't want to make any change to the origin

  • Problems with accessing V$SQLAREA, V$SQL, V$SQLTEXT, and V$SQL_PLAN

    Hi there, I created a new user account and granted it dba. I logged on to this account and I am trying to run select statments on V$SQLAREA, V$SQL, V$SQLTEXT, and V$SQL_PLAN, but I am getting ORA-00942: table or view does not exist 00942. 00000 - "ta

  • MacBook 2,1 upgrading to 10.6.*

    I have upgraded to 3GB ram and have 95GB disk space free. I am happy with my OS but I just have to have the latest and greatest, short of buying a new mac How much of a risk is this, what other prep should I make on my old book? I cant afford a backu

  • Can I edit pdf files on a mac?

    I have Acrobat Reader on my MAC osx 10.6.8.  I need to edit an pdf document. I guess I need to buy an Acrobat software (Pro way too expensive and beyond what I need).  I tried to download the latest Acrobat Standard X package, but it does not seem co

  • My iPhone 4 died and won't turn back on. It's been on the charger for 17 hours.

    Last night my phone went completely dead while I was doing something for school. I put it on the charger as soon as I got into the car, maybe 30 minutes after it went dead. It's been charging for 17 hours and still shows an empty battery with a flash