Table of type select-options

Hi,
I need to build an internal table which has the fields SIGN, OPTION, LOW, HIGH.
I know there exists a standard database table with these 4 fields, but, am not able to recollect.
Please post the table name here if you know.
Thanks,
David.

Are you looking for this table -
>TVARVC
Alternatively,if u have the field name.
You can use this declaration
RANGES :r_matnr for mara-matnr. (or)
DATA:r_matnr1 type range of mara-matnr.---->Internal table having components  SIGN ,OPTION,matnr-LOW,matnr-HIGH
DATA:wa_matnr1 like line of r_matnr1.------->Work Area
Regards,
Lakshman.
Edited by: Lakshman N on Oct 29, 2009 7:19 AM

Similar Messages

  • Internal table values to select-options

    Hi,
    I have to modify an existing program.
    here
    1. I am populating one field in the selection-screen with a file path which contain  some data.
    2. then this file i am converting into an internal table.(At selection-screen event)
    <b>Now, i have to pass this data of the internal table to a select-option in the selection-screen back.</b>
    how it is possible, i have tried a lot.
    please help me.
    Regards,
    Maahi.

    tables bkpf.
    data: begin of itab occurs 0.
    INCLUDE STRUCTURE alsmex_tabline.
    data end of itab.
    PARAMETERS p_fpath like rlgrap-filename.
    SELECT-OPTIONS rbelnr FOR bkpf-belnr.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_fpath.
    CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
    EXPORTING
    *   PROGRAM_NAME        = SYST-REPID
    *   DYNPRO_NUMBER       = SYST-DYNNR
    *   FIELD_NAME          = ' '
       STATIC              = 'X'
    *   MASK                = ' '
      CHANGING
        FILE_NAME           = p_fpath
    * EXCEPTIONS
    *   MASK_TOO_LONG       = 1
    *   OTHERS              = 2
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
      EXPORTING
        FILENAME                      = p_fpath
        I_BEGIN_COL                   = 1
        I_BEGIN_ROW                   = 1
        I_END_COL                     = 1
        I_END_ROW                     = 2000
      TABLES
        INTERN                        = itab
    * EXCEPTIONS
    *   INCONSISTENT_PARAMETERS       = 1
    *   UPLOAD_OLE                    = 2
    *   OTHERS                        = 3
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    sort itab by value.
    delete adjacent duplicates from itab comparing value.
    now after this i have to implement the logic in 3rd point.
    thanks ,
    Maahi

  • How to set BDCDATA table for a SELECT-OPTIONS object?

    Dear experts,
    I have a transaction with PARAMETERS and SELECT-OPTIONS objects. This transaction will be called by another program by using CALL TRANSACTION 'mytransaction' USING mybdcdata statement. Below is some of the called transaction's source code:
    DATA:
      date TYPE sflight-fldate.
    PARAMETERS:
      p_carid TYPE sflight-carrid,
      p_conid TYPE sflight-connid.
    SELECT-OPTIONS:
      so_date FOR date.
    This is what I wrote in the calling program to define the values of the called transaction PARAMETERS fields:
    DATA:
      wa_bdcdata TYPE bdcdata,
      it_bdcdata TYPE TABLE OF bdcdata.
    wa_bdcdata-program = 'MYPROGRAM'.
    wa_bdcdata-dynpro = '1000'.
    wa_bdcdata-dynbegin = 'X'.
    APPEND wa_bdcdata TO it_bdcdata.
    CLEAR wa_bdcdata.
    wa_bdcdata-fnam = 'P_CARID'.
    wa_bdcdata-fval = 'AA'.
    APPEND wa_bdcdata TO it_bdcdata.
    CLEAR wa_bdcdata.
    wa_bdcdata-fnam = 'P_CONID'.
    wa_bdcdata-fval = '017'.
    APPEND wa_bdcdata TO it_bdcdata.
    CALL TRANSACTION 'MYTRANSACTION' USING it_bdcdata.
    Unfortunately, I don't know how to set the values for the SELECT-OPTIONS screen fields. How to do this?
    I've Googled this and tried several guesses but none was found or successful. Thanks in advance.
    Regards,
    Haris

    Hi ,
      Better go for  SUBMIT report   instead of CALL transaction  ...
      find the name  of  report being called  on that transaction which you will be calling  . Use that report name in SUBMIT 
    Just take help from  below code .
    Before using do please read  by pressing f1 on SUBMIT  syntax .
    data:seltab     type table of rsparams,
             seltab_wa  like line of seltab.
        move: 'LANGU'  to seltab_wa-selname,
              'S'      to seltab_wa-kind,
              'I'      to seltab_wa-sign,
              'BT'     to seltab_wa-option,
              'D'      to seltab_wa-low,
              'I'      to seltab_wa-high.
        append seltab_wa to seltab.
        clear seltab_wa.
        move: 'E'      to seltab_wa-sign,
              'EQ'     to seltab_wa-option,
              'F'      to seltab_wa-low,
              space    to seltab_wa-high.
        append seltab_wa to seltab.
        clear seltab_wa.
        move: 'AUFNR' to seltab_wa-selname,
              p_aufnr to seltab_wa-low.
        append seltab_wa to seltab.
        clear seltab_wa.
        submit rkaep000  using selection-set 'VARIANT1'
                          with aufnr = p_aufnr
                          with selection-table seltab
                          exporting list to memory
                          and return .
    regards
    Deepak.

  • Assigning Data-Type Select-Option from Report to Method

    Hi Specialists,
    How can I solve the following task smart?  It’s a quiet simple task. In my Report I’ve some Select-Option-Data-Types and I want to assign this data-type an Abpab-Object-Method. Is it possible to do this in a smart fashion. I’ve fight with the Abap-Syntax und at the end I’ve found a tricky way of assigning the Select-Option parameter to the Abap-Object-Method.
    If somebody have a smart idea for this problem, pleas let me know.
    Thankx.
    Hallo Spezialisten,
    ich hätte da eine Frage wie man folgende Aufgabe elegant lösen kann.
    Es ist ganz einfach, ich möchte von einen Report einen Select-Option-Datentyp an eine Abapobject Methode übergeben. Ich hatte sehr lange gekämpft bis ich ein umständlichen weg gefunden habe die parameter vom reprot an die mehtode zu übergen.
    Falls jemand da eine gut Idee hätte wäre mir das nächste mach sehr geholfen.
    Danke

    Hi 
    Here is the Program with  Selection screen and   the Class & Methods.
    REPORT demo_abap_objects_methods NO STANDARD PAGE HEADING.
    * Global Selection Screens
    SELECTION-SCREEN BEGIN OF: SCREEN 100 TITLE tit1, LINE.
    PARAMETERS members TYPE i DEFAULT 10.
    SELECTION-SCREEN END OF: LINE, SCREEN 100.
    SELECTION-SCREEN BEGIN OF: SCREEN 200 TITLE tit2.
    PARAMETERS: drive    RADIOBUTTON GROUP actn,
                stop     RADIOBUTTON GROUP actn,
                gearup   RADIOBUTTON GROUP actn,
                geardown RADIOBUTTON GROUP actn.
    SELECTION-SCREEN END OF: SCREEN 200.
    * Class Definitions
    CLASS: c_biker DEFINITION DEFERRED,
           c_bicycle DEFINITION DEFERRED.
    CLASS c_team DEFINITION.
      PUBLIC SECTION.
        TYPES: biker_ref TYPE REF TO c_biker,
               biker_ref_tab TYPE STANDARD TABLE OF biker_ref
                                           WITH DEFAULT KEY,
               BEGIN OF status_line_type,
                 flag(1)  TYPE c,
                 text1(5) TYPE c,
                 id       TYPE i,
                 text2(7) TYPE c,
                 text3(6) TYPE c,
                 gear     TYPE i,
                 text4(7) TYPE c,
                 speed    TYPE i,
               END OF status_line_type.
        CLASS-METHODS: class_constructor.
        METHODS: constructor,
                 create_team,
                 selection,
                 execution.
      PRIVATE SECTION.
        CLASS-DATA: team_members TYPE i,
                    counter TYPE i.
        DATA: id TYPE i,
              status_line TYPE status_line_type,
              status_list TYPE SORTED TABLE OF status_line_type
                               WITH UNIQUE KEY id,
              biker_tab TYPE biker_ref_tab,
              biker_selection LIKE biker_tab,
              biker LIKE LINE OF biker_tab.
        METHODS: write_list.
    ENDCLASS.
    CLASS c_biker DEFINITION.
      PUBLIC SECTION.
        METHODS: constructor IMPORTING team_id TYPE i members TYPE i,
                 select_action,
                 status_line EXPORTING line TYPE c_team=>status_line_type.
      PRIVATE SECTION.
        CLASS-DATA counter TYPE i.
        DATA: id TYPE i,
              bike TYPE REF TO c_bicycle,
              gear_status  TYPE i VALUE 1,
              speed_status TYPE i VALUE 0.
        METHODS biker_action IMPORTING action TYPE i.
    ENDCLASS.
    CLASS c_bicycle DEFINITION.
      PUBLIC SECTION.
        METHODS: drive EXPORTING velocity TYPE i,
                 stop  EXPORTING velocity TYPE i,
                 change_gear IMPORTING change TYPE i
                             RETURNING value(gear) TYPE i
                             EXCEPTIONS gear_min gear_max.
      PRIVATE SECTION.
        DATA: speed TYPE i,
              gear  TYPE i VALUE 1.
        CONSTANTS: max_gear TYPE i VALUE 18,
                   min_gear TYPE i VALUE 1.
    ENDCLASS.
    * Class Implementations
    CLASS c_team IMPLEMENTATION.
      METHOD class_constructor.
        tit1 = 'Team members ?'.
        CALL SELECTION-SCREEN 100 STARTING AT 5 3.
        IF sy-subrc NE 0.
          LEAVE PROGRAM.
        ELSE.
          team_members = members.
        ENDIF.
      ENDMETHOD.
      METHOD constructor.
        counter = counter + 1.
        id = counter.
      ENDMETHOD.
      METHOD create_team.
        DO team_members TIMES.
          CREATE OBJECT biker EXPORTING team_id = id members = team_members.
          APPEND biker TO biker_tab.
          CALL METHOD biker->status_line IMPORTING line = status_line.
          APPEND status_line TO status_list.
        ENDDO.
      ENDMETHOD.
      METHOD selection.
        CLEAR biker_selection.
        DO.
          READ LINE sy-index.
          IF sy-subrc <> 0. EXIT. ENDIF.
          IF sy-lisel+0(1) = 'X'.
            READ TABLE biker_tab INTO biker INDEX sy-index.
            APPEND biker TO biker_selection.
          ENDIF.
        ENDDO.
        CALL METHOD write_list.
      ENDMETHOD.
      METHOD execution.
        CHECK NOT biker_selection IS INITIAL.
        LOOP AT biker_selection INTO biker.
          CALL METHOD biker->select_action.
          CALL METHOD biker->status_line IMPORTING line = status_line.
          MODIFY TABLE status_list FROM status_line.
        ENDLOOP.
        CALL METHOD write_list.
      ENDMETHOD.
      METHOD write_list.
        SET TITLEBAR 'TIT'.
        sy-lsind = 0.
        SKIP TO LINE 1.
        POSITION 1.
        LOOP AT status_list INTO status_line.
          WRITE: / status_line-flag AS CHECKBOX,
                   status_line-text1,
                   status_line-id,
                   status_line-text2,
                   status_line-text3,
                   status_line-gear,
                   status_line-text4,
                   status_line-speed.
        ENDLOOP.
      ENDMETHOD.
    ENDCLASS.
    CLASS c_biker IMPLEMENTATION.
      METHOD constructor.
        counter = counter + 1.
        id = counter - members * ( team_id - 1 ).
        CREATE OBJECT bike.
      ENDMETHOD.
      METHOD select_action.
        DATA activity TYPE i.
        tit2 = 'Select action for BIKE'.
        tit2+24(3) = id.
        CALL SELECTION-SCREEN 200 STARTING AT 5 15.
        CHECK NOT sy-subrc GT 0.
        IF gearup = 'X' OR geardown = 'X'.
          IF gearup = 'X'.
            activity = 1.
          ELSEIF geardown = 'X'.
            activity = -1.
          ENDIF.
        ELSEIF drive = 'X'.
          activity = 2.
        ELSEIF stop = 'X'.
          activity = 3.
        ENDIF.
        CALL METHOD biker_action( activity ).
      ENDMETHOD.
      METHOD biker_action.
        CASE action.
          WHEN -1 OR 1.
            CALL METHOD bike->change_gear
                              EXPORTING change = action
                              RECEIVING gear = gear_status
                              EXCEPTIONS gear_max = 1
                                         gear_min = 2.
            CASE sy-subrc.
              WHEN 1.
                MESSAGE i315(at) WITH 'BIKE' id
                                      ' is already at maximal gear!'.
              WHEN 2.
                MESSAGE i315(at) WITH 'BIKE' id
                                      ' is already at minimal gear!'.
            ENDCASE.
          WHEN 2.
            CALL METHOD bike->drive IMPORTING velocity = speed_status.
          WHEN 3.
            CALL METHOD bike->stop  IMPORTING velocity = speed_status.
        ENDCASE.
      ENDMETHOD.
      METHOD status_line.
        line-flag = space.
        line-text1 = 'Biker'.
        line-id = id.
        line-text2 = 'Status:'.
        line-text3 = 'Gear = '.
        line-gear  = gear_status.
        line-text4 = 'Speed = '.
        line-speed = speed_status.
      ENDMETHOD.
    ENDCLASS.
    CLASS c_bicycle IMPLEMENTATION.
      METHOD drive.
        speed = speed  + gear * 10.
        velocity = speed.
      ENDMETHOD.
      METHOD stop.
        speed = 0.
        velocity = speed.
      ENDMETHOD.
      METHOD change_gear.
        gear = me->gear.
        gear = gear + change.
        IF gear GT max_gear.
          gear = max_gear.
          RAISE gear_max.
        ELSEIF gear LT min_gear.
          gear = min_gear.
          RAISE gear_min.
        ENDIF.
        me->gear = gear.
      ENDMETHOD.
    ENDCLASS.
    * Global Program Data
    TYPES team TYPE REF TO c_team.
    DATA: team_blue  TYPE team,
          team_green TYPE team,
          team_red   TYPE team.
    DATA  color(5) TYPE c.
    * Program events
    START-OF-SELECTION.
      CREATE OBJECT: team_blue,
                     team_green,
                     team_red.
      CALL METHOD: team_blue->create_team,
                   team_green->create_team,
                   team_red->create_team.
      SET PF-STATUS 'TEAMLIST'.
      WRITE '                   Select a team!             ' COLOR = 2.
    AT USER-COMMAND.
      CASE sy-ucomm.
        WHEN 'TEAM_BLUE'.
          color = 'BLUE '.
          FORMAT COLOR = 1 INTENSIFIED ON INVERSE ON.
          CALL METHOD team_blue->selection.
        WHEN 'TEAM_GREEN'.
          color = 'GREEN'.
          FORMAT COLOR = 5 INTENSIFIED ON INVERSE ON.
          CALL METHOD team_green->selection.
        WHEN 'TEAM_RED'.
          color = 'RED '.
          FORMAT COLOR = 6 INTENSIFIED ON INVERSE ON.
          CALL METHOD team_red->selection.
        WHEN 'EXECUTION'.
          CASE color.
            WHEN 'BLUE '.
              FORMAT COLOR = 1 INTENSIFIED ON INVERSE ON.
              CALL METHOD team_blue->selection.
              CALL METHOD team_blue->execution.
            WHEN 'GREEN'.
              FORMAT COLOR = 5 INTENSIFIED ON INVERSE ON.
              CALL METHOD team_green->selection.
              CALL METHOD team_green->execution.
            WHEN 'RED '.
              FORMAT COLOR = 6 INTENSIFIED ON INVERSE ON.
              CALL METHOD team_red->selection.
              CALL METHOD team_red->execution.
          ENDCASE.
      ENDCASE.
    Reward  points if it is usefull ....
    Girish

  • Table View MULTI SELECT option and Event handling problems

    Hello All,
    I am facing problem while giving miltselect option in a table view. When i mention multiselect attribute in Select option in table view, i am unable to select all the rows which i want to select,because i have an event onRowSelection event activated so when i select a row then it will automatically go to the event and i am unable to do multiple select.
    Can you guys pl tell me is there any way thtat i can put check boxes in a table column and by that i can get values of row seelct and can perform my subsequent SQL operation.
    Also i am not able to navigate in table view through BYPAGE or BYLINE option. When I click on navigate button then page got refreshed and i lost data.
    One more query guys , can you pl tell me how can i store my internal table values from one event for the another event. I have used EXport/Import but internal table values get refreshed as page got refreshed on event switching/selection.
    Please respond.

    hye rahul.
      as i told you my second solution, will help you . the values remain in the corresponding UI elements.
    For example , you have a drop down and table view. both will trigger events. bind the data of the table at drop down event and bind the dat of the drop down at table event.
    event = cl_htmlb_manager=>get_event( runtime->server->request ).
    CASE event->id.
    when 'dd1'.                   drop down event is fired.
    bind data for drop down
    dd ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'dropdown'
                                          id      = dd_id'           " name of the drop down id
    along with drop down bind data for table view
        tbv ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'tableView'
                                          id      = 'tbv_id'           " name of the table view
    when 'tbv_id'.                   drop down event is fired.
    bind data for drop down
    dd ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'dropdown'
                                          id      = dd_id'           " name of the drop down id
    along with drop down bind data for table view
        tbv ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'tableView'
                                          id      = 'tbv_id'           " name of the table view
    This is how data should be binded in case of Stateless application. All the UI elemets must b binded again.. as the global data is refresed again.
    Hope this helps.
    Regards,
    Imran.

  • Using variable in physical table of type "select"

    Hello!
    I have to use query as physical table (in Administration tool - http://file.qip.ru/file/120930377/8713693/1_online.html):
    SELECT ID, CODE
    FROM TABLE (pkg.output('1','2')) This code works well. I need to insert instead of parameters '1' and '2' session variables, which will be set from Dashboard.
    How to put variable in this query? Variants like @{test} don't work.

    Hi
    I have a working example:
    select * from table(get_emps('VALUEOF(NQ_SESSION.USER)'))
    where
    CREATE OR REPLACE FUNCTION GET_EMPS(P_USER VARCHAR2:='SUPPLIER2')
    RETURN EMP_TYPE_LIST
    IS
    EMPS EMP_TYPE_LIST:=EMP_TYPE_LIST();
    R EMP_TYPE:=EMP_TYPE(NULL,NULL,NULL,NULL,NULL);
    i pls_integer:=0;
    CURSOR C_EMP(C_USER EMPLOYEES.USER_ID%TYPE) IS
    SELECT EMPLOYEE_ID,FIRST_NAME,LAST_NAME,SALARY ,USER_ID
    FROM EMPLOYEES WHERE upper(USER_ID)=upper(C_USER);
    BEGIN
    OPEN C_EMP(P_USER);
    LOOP
    FETCH C_EMP INTO R.EMPLOYEE_ID,R.FIRST_NAME,R.LAST_NAME,R.SALARY,R.USER_ID;
    EXIT WHEN C_EMP%NOTFOUND;
    i:=i+1; emps.extend; EMPS(i):=R;
    END LOOP;
    RETURN EMPS;
    END;
    and
    CREATE OR REPLACE TYPE EMP_TYPE AS OBJECT
    EMPLOYEE_ID NUMBER(6),
    FIRST_NAME VARCHAR2(20),
    LAST_NAME VARCHAR2(25),
    SALARY NUMBER(8,2),
    USER_ID VARCHAR2(30));
    and
    CREATE OR REPLACE TYPE EMP_TYPE_LIST AS TABLE OF EMP_TYPE;
    My employees table contains an extra column, called user_id, which has different values: 'Administrator','SUPPLIER2' and so on
    Best regards
    Laszlo

  • List with multiple custom content types - Show content type selection option in the list newform page

    In my project I am using SharePoint Online 2013 and there is a custom list with two content types. While creating a new item in that list, can we show the content type drop down list along with other columns? While editing an item I am able to view the content
    type dropdown in the edit form associated with the list. Can we enable the same for the default newform as well?

    In my project I am using SharePoint Online 2013 and there is a custom list with two content types. While creating a new item in that list, can we show the content type drop down list along with other columns? While editing an item I am able to view the content
    type dropdown in the edit form associated with the list. Can we enable the same for the default newform as well?

  • Why we use Tables statement in case of using SELECT-OPTIONS:

    hi all,
    Why we use Tables statement in case of using the following coding in an ABAP program ...
    tables: vbak.
    SELECT-OPTIONS: s1 for vbak-vbeln.
    here if we dont provide the tables statement why it does not work ????
    pls answwer ....???

    Hi
    This statement is not allowed in classes and declares a data object table_wa as a table work area whose data type is adopted from the identically named structured data type table_wa from the ABAP Dictionary. table_wa must be defined as a flat structure in the ABAP Dictionary. You can specify database tables or Views for table_wa.
    Work table areas declared with TABLES are interface work areas and should only be declared in the global declaration section of a program for the following purpose:
    reward if usefull
    The statement TABLES is required for exchanging data between screen fields that were defined in a program screen when transferring from the ABAP Dictionary and the ABAP program. For the screen event PBO, the content of the table work area is transferred to identically named screen fields; for PAI, the system adopts the data from identically named screen fields.
    In executable programs, flat table work areas can be used for adopting data that were provided for the event GET table_wa from a linked logical database. TABLES is synonymous with the statement NODES for this purpose.
    Work table areas declared with TABLES behave like the data declared with the addition COMMON PART, meaning the data are used by the programs of a program group.
    Table work areas declared with TABLES can be declared in subroutines and
    function modules. However, this is not recommended. A table work area declared in a procedure is not local but belongs to the context of a framework program. The table work area can be viewed starting from the declaration in the framework program and lives as long as the framework program. In contrast to normal program-global data, the content of the table work areas declared in subroutines and function modules is stored temporarily when these subroutines and function modules are called. Value assignments that were made during runtime of the procedure are preserved until the procedure is completed. When exiting the procedure, the table work areas are filled with the contents that they contained when the procedure was called. Table work areas declared in procedures behave like global data to which the statement LOCAL is applied in the procedure.
    The form TABLES * is obsolete.

  • Passing select options internal table to BAPI attributes...

    Hello Web Dynpro Gurus,
    When I get the values from select options into interna table, how can I pass the same to the attribtues of the importing/exporting nodes of the BAPI by reading the context.
    Please help .
    Regards,
    Jainam.

    Hello,
    The code in bold below sets attributes  of my node one by one for the select option node atttributes i.e. SIGN, OPTION, LOW and HIGH.
    Instead of that how can I set all attributes of node which is of type select-options in one shot.
    method ONACTIONSEARCH .
    DATA: S_WAERS TYPE REF TO DATA.
    FIELD-SYMBOLS:  <FS_WAERS> TYPE TABLE.
    Retrieve the data from the select option
      S_WAERS = WD_THIS->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD( I_ID = 'WAERS' ).
      Assign it to a field symbol
       ASSIGN S_WAERS->* TO <FS_WAERS>.
       data:
        Node_Rep_Curr                       type ref to If_Wd_Context_Node,
        Elem_Rep_Curr                       type ref to If_Wd_Context_Element,
        Stru_Rep_Curr                       type If_Select_View=>Element_Rep_Curr .
    navigate from <CONTEXT> to <REP_CURR> via lead selection
      Node_Rep_Curr = wd_Context->get_Child_Node( Name = IF_SELECT_VIEW=>wdctx_Rep_Curr ).
    get element via lead selection
      Elem_Rep_Curr = Node_Rep_Curr->get_Element(  ).
    get all declared attributes
      Elem_Rep_Curr->get_Static_Attributes(
        importing
          Static_Attributes = Stru_Rep_Curr ).
        Node_Rep_Curr->set_attribute(
        Exporting
          name = 'SIGN'
          value = 'I' ).{code}
    endmethod.
    Edited by: Jainam Shah on Feb 5, 2010 2:55 PM

  • How to make select-option for one inner table

    Hi,
    Who can teach me to  make select-option for a inner table, which let select-option display data from this inner table.
    Thanks in advance.

    Is this what you are looking for?
    report zrich_0002.
    data: begin of itab occurs 0,
          matnr type mara-matnr,
          spras type makt-spras,
          maktx type makt-maktx,
          end of itab.
    select-options: s_matnr for itab-matnr.
    select-options: s_spras for itab-spras.
    start-of-selection.
      select mara~matnr makt~spras makt~maktx
               into corresponding fields of table itab
                      from mara
                            inner join makt
                               on mara~matnr = makt~matnr
                                        where mara~matnr in s_matnr
                                          and makt~spras in s_spras.
      check sy-subrc = 0.
    Regards,
    Rich Heilman

  • Update a select-option From Table

    Hi,
    I'm originally a C++ developer trying to learn ABAP.
    I want to append values to a select-option from a table if another select-option is specified.  I wrote some code that I believe will work but looks very inefficient to me.  Any advice on how to streamline this process would appreciated.
    The following is pseudo code and I left out some tweaks for simplicity and understanding but the basic idea is there.  I want to add selection criteria to a select-option based upon a second select option (that may or may not be provided) table lookup.
    Example:
    DATA: groups TYPE table3.
    SELECT-OPTIONS:
         s_accountNo FOR table1-accountNo,
         s_accountGroupNo FOR table2-accountGroupNo.
    **** get the Account Groups that meet the selection criteria.
    START-OF-SELECTION
         SELECT * INTO TABLE groups
              FROM table3
              WHERE accountGroupNo IN s_accountGroupNo.
    **** Remove duplicate accounts from the Account Groups
    SORT groups BY accountNo.
    DELETE ADJACENT DUPLICATES FROM groups COMPARING accountNo.
    **** Append the account #'s onto the s_accountNo range/select-option
    LOOP AT groups.
         APPEND groups-accountNo TO s_accountNo.
    ENDLOOP.
    **** manually edit the  s_accountNo to have the correct option/sign for use in further select statements.
    LOOP AT s_accountNo.
         s_accountNo-sign = 'I'.
         s_accountNo-option = 'EQ'.
         MODIFY s_accountNo.
    ENDLOOP.
    Thanks much,
    -Chris

    The actual selection is fairly complicated from my point of view.  I wrote the accountNo example to make things less confusing for me as much as anyone else, not to hide anything.  I also didn't expect this amount of feedback, though it is appreciated.
    The eventual select statement that is done is the following:
      SELECT DISTINCT vttp~zseq_num
                      likp~vbeln
                      likp~lprio
                      likp~vstel
                      lips~werks
                      likp~lgnum
                      lips~posnr
                      lips~lgort
                      lips~vgbel
                      lips~vgpos
                      lips~sobkz
                      lips~lfimg
                      lips~vrkme
                      lips~matnr
                      lips~volum
                      mara~raube
                      vttk~dplbg
                      vttp~tknum
                      vttp~tpnum
                      likp~berot
                      likp~vkorg
                      likp~lfart
                      INTO TABLE temp_deliveries
      FROM vttk
           INNER JOIN vttp
           ON vttk~tknum = vttp~tknum
           INNER JOIN likpuk AS likp
           ON vttp~vbeln = likp~vbeln
           INNER JOIN lipsup AS lips
           ON likp~vbeln = lips~vbeln
           INNER JOIN mara
           ON lips~matnr = mara~matnr
      WHERE likp~vstel = p_vstel
        AND lips~werks = p_werks
        AND likp~lgnum IN s_lgnum
        AND likp~vbeln IN s_vbeln
        AND lips~vgbel IN s_vgbel
        AND vttk~dplbg IN s_dplbg
        AND vttk~tknum IN s_tknum
        AND mara~raube = p_raube
        AND likp~lfart IN ('ZLF', 'NL')
        AND lips~kosta <> 'C'
        AND lips~kosta <> ''
        AND likp~kostk <> 'C'
        AND likp~vbtyp = outbound.
    and the structure it is put into is the following:
    TYPES: BEGIN OF type_deliveries,
              zseq_num    TYPE vttp-zseq_num,
              vbeln       TYPE likp-vbeln,
              lprio       TYPE likp-lprio,
              vstel       TYPE likp-vstel,
              werks       TYPE likp-werks,
              lgnum       TYPE likp-lgnum,
              posnr       TYPE lips-posnr,
              lgort       TYPE lips-lgort,
              vgbel       TYPE lips-vgbel,
              vgpos       TYPE lips-vgpos,
              sobkz       TYPE lips-sobkz,
              lfimg       TYPE lips-lfimg,
              vrkme       TYPE lips-vrkme,
              matnr       TYPE lips-matnr,
              volum       TYPE lips-volum,
              raube       TYPE mara-raube,
              dplbg       TYPE vttk-dplbg,
              tknum       TYPE vttk-tknum,
              tpnum       TYPE vttp-tpnum,
              berot       TYPE likp-berot,
              vkorg       TYPE likp-vkorg,
              lfart       TYPE likp-lfart,
              sdabw       type likp-sdabw,
              orig_lgort  TYPE lips-zzorig_lgort,
              selected    TYPE flag,
              counter(15) TYPE n,
            END OF type_deliveries.
    Currently there is a select option for tknum and I am attempting (successfully with my change shown above, though as many have pointed out I may be misusing the intended functionality) to add another select-option for s_pickno which is a field of a custom table that has pickno as one of it's unique keys and tknum as another of it's fields.  The idea is to be able to take a pickno and use it to find all the tknum's associated and then use them in the select statement above as well as any tknum's provided as initial input by the user.  If there is a better method than modifying the s_tknum selection I'm open to feedback.
    Apologies that my initial example did not portray this, but being new I was a little overwhelmed myself and want something I can wrap my head around better.  There's my wall of text

  • SELECT-OPTIONS can u use it to read internal table ?????

    Hello All,
       I am trying to read an internal table with the select-options statement. I am getting a syntax error so i am hoping i am just coding it incorrectly. Can someone tell me what is wrong here is the if statement :
    if p_begdte in t_rpt-datab and
           p_enddte in t_rpt-datbi.
        else.
           exit.
        endif.
    thanks scott

    This is not working?
    tables: a916.
    * Beg valid date *
    data text021(29).
    selection-screen begin of line.
    selection-screen comment 1(30) text-021 for field p_begdte.
    selection-screen position 32.
    select-options: p_begdte for a916-datab default '20041101' to
    '99991231'.
    selection-screen end of line.
    * End valid date *
    data text022(29).
    selection-screen begin of line.
    selection-screen comment 1(30) text-022 for field p_enddte.
    selection-screen position 32.
    select-options: p_enddte for a916-datbi default '20041101' to
    '99991231'.
    selection-screen end of line.
    start-of-selection.
    <b>Loop at t_rpt.
    if t_rpt-datab in p_begdte
      and t_rpt-datbi in p_endte.
    * do something
    else.
    exit.
    endif
    Endloop.</b>
    Regards,
    Rich Heilman

  • How to bind select options type(LEDAT) to attribute?

    Hi All,
    I am using SHP_EXTENDED_DUE_LIST FM, in this IX_SELECT_OPTIONS node contains LEDAT, but it is of type select options.
    I want to bind this to date type attribute.
    Delivery date :__ to __.
    while executing original FM we are giving low and high values it is giving output, but while binding i am getting only LEDAT but type is different. how to process this?? Please Help.
    Thanks,
    VEnky.

    Hi Sarbjeet,
    I am trying like this...
    DATA: r_date TYPE SHP_LEDAT_RANGE,
            r_plant TYPE SHP_VSTEL_RANGE,
            L_IX_SELECT_OPTIONS  TYPE SHP_VL10_SELECT_OPTIONS,
            L_EX_DELIVERY         TYPE SHP_VL10_DELIVERY,
            L_IX_PARAMETERS       TYPE SHP_VL10_PARAMETERS.
      DATA: ld_from_date TYPE d,
            ld_to_date   TYPE d.
      DATA lo_nd_input TYPE REF TO if_wd_context_node.
      DATA lo_el_input TYPE REF TO if_wd_context_element.
      DATA ls_input TYPE wd_this->Element_input.
      DATA lv_del_cdate TYPE wd_this->Element_input-del_cdate.
      DATA lv_to_date TYPE wd_this->Element_input-to_date.
      DATA lv_ship_point TYPE wd_this->Element_input-ship_point.
    navigate from <CONTEXT> to <INPUT> via lead selection
      lo_nd_input = wd_context->get_child_node( name = wd_this->wdctx_input ).
      lo_el_input = lo_nd_input->get_element( ).
    get single attribute
      lo_el_input->get_attribute(
        EXPORTING
          name =  `DEL_CDATE`
        IMPORTING
          value = lv_del_cdate ).
    get single attribute
      lo_el_input->get_attribute(
        EXPORTING
          name =  `TO_DATE`
        IMPORTING
          value = lv_to_date ).
      r_date-sign   = 'I'.
      r_date-option = 'BT'.
      r_date-low    = lv_del_cdate .
      r_date-high   = lv_to_date.
      APPEND r_date to  L_IX_SELECT_OPTIONS-ledat.
      CLEAR r_date.
    get single attribute
      lo_el_input->get_attribute(
        EXPORTING
          name =  `SHIP_POINT`
        IMPORTING
          value = lv_ship_point ).
      r_plant-sign = 'I'.
      r_plant-option = 'EQ'.
      r_plant-low = lv_ship_point.
      r_plant-high = ''.
      APPEND r_plant to L_IX_SELECT_OPTIONS-VSTEL.
      CLEAR r_plant.
      CALL FUNCTION 'SHP_EXTENDED_DUE_LIST'
        EXPORTING
          IX_PARAMETERS               = L_IX_PARAMETERS
          IX_SELECT_OPTIONS           = L_IX_SELECT_OPTIONS .
      DATA lo_COMPONENTCONTROLLER TYPE REF TO IG_COMPONENTCONTROLLER .
      lo_COMPONENTCONTROLLER =   wd_this->get_componentcontroller_ctr( ).
      lo_componentcontroller->execute_shp_extended_due_list(  ).
    But i am getting this error : Screen output without connection to user.
    CAN U TELL ME ANY THING WRONG IN THIS??
    tHANKS,
    vENKY.
    Edited by: venkys on Mar 8, 2011 9:52 AM

  • Select-option in ABAP objects

    Hi Guys,
               I need a small help from you. I want to know how to populate the value from select-option to abap object. Please help me, it is very important

    check this code
    REPORT ZSELOPT_TO_CLASS .
    TABLES: VBRK.
    SELECT-OPTIONS: S_VBELN FOR VBRK-VBELN.
    DATA: IT_VBELN TYPE RSELOPTION.
    DATA: X_VBELN TYPE RSDSSELOPT.
    CLASS C1 DEFINITION.
    PUBLIC SECTION.
    DATA: IT_VBRP TYPE VBRP_TAB,
          X_VBRP LIKE LINE OF IT_VBRP.
    METHODS: GET_DATA IMPORTING S_VBELN TYPE RSELOPTION.
    METHODS: DISP_DATA.
    ENDCLASS.
    CLASS C1 IMPLEMENTATION.
    METHOD GET_DATA.
      *SELECT * FROM VBRP*
       INTO TABLE IT_VBRP
       WHERE VBELN IN S_VBELN.
    ENDMETHOD.
    METHOD DISP_DATA.
      LOOP AT IT_VBRP INTO X_VBRP.
        WRITE:/ X_VBRP-VBELN,
                X_VBRP-POSNR.
      ENDLOOP.
    ENDMETHOD.
    ENDCLASS.
    START-OF-SELECTION.
    DATA OBJ TYPE REF TO ZCL_SELOPT.
    CREATE OBJECT OBJ.
    LOOP AT S_VBELN.
      MOVE S_VBELN-LOW TO X_VBELN-LOW.
      MOVE S_VBELN-HIGH TO X_VBELN-HIGH.
      MOVE S_VBELN-SIGN TO X_VBELN-SIGN.
      MOVE S_VBELN-OPTION TO X_VBELN-OPTION.
      APPEND X_VBELN TO IT_VBELN.
    ENDLOOP.
    CALL METHOD OBJ->GET_DATA
                        EXPORTING
                          S_VBELN = IT_VBELN.
    CALL METHOD OBJ->DISP_DATA.
    Edited by: moazam hai on May 17, 2008 6:17 AM
    Edited by: moazam hai on May 17, 2008 6:19 AM

  • Select options for a file

    Hello all,
    At the moment iam using parameters for actual file and its path
    for eg:
    PARAMETERS: p_file(100) TYPE c .
    i want to go for select-options so that i can use multiple files at the same time.....plz advise
    regards

    hi Sudher,
    TABLES : rlgrap.
    SELECT-OPTIONS : s_file FOR rlgrap-filename NO INTERVALS.
    hope this helps
    ec

Maybe you are looking for

  • Purchase order history in PO

    Hi everyone, Could you please say where i have the link to change the reference doc field which appears in PO history tab of PO.  Help says that it can have the reference number of vendor or customer.  Where do i change it. Siva

  • Created a trigger but new values are not inserting in the backup table

    I have created a backup table and writter a trigger on a table such that after update old values and new values are to be inserted into the backup table, but new values are not inserting. I am giving the code please help me create or replace trigger

  • How can I catch and display the "cent" symbol (Alt+0162)?

    Hi, I have a jTextArea field in which it supposes to be able to catch a special character, money cent symbol by Alt+0162 from the keyboard. Does anyone know how I can catch it and display it in money cent symbol in the jTextArea field? Thanks for you

  • VO Extension or Substitution Help Please - Urgent (iExpenses)

    Hi All, I am trying to limit the data of the Projects and Tasks LOV (on the ExpenseAllocationsPG) in iExpenses Module. I tried a VO substitution and failed with an error. ERROR: oracle.jbo.NoDefException: JBO-25002: Definition type View Definition no

  • Folio Builder Sign-In Issues (yes, I know I'm the 1,000th person to post this!)

    I'm about to go insane... I can't sign into the Folio Builder panel in InDesign CC (v9.1 x64).  I must have been asked 12 times today to sign into CC, and accept the license agreement another 6 times.  I was signed into the Folio Builder panel most o