Problem with generic table in tableview

Hi,
I need a generic editable table in my tableview. I coded the page as shown below. Displaying the data works fine but after editing, the modifications are not present in my variable model->table. It seems that my reference is lost.
How can I solve this problem
  field-symbols: <tab> type table.
  assign model->table->* to <tab>.
  if <tab> is assigned.
%>
<htmlb:tableView id              = "itab"
                  selectionMode   = "LINEEDIT"
                  table           = "<%= <tab> %>"
                  columnDefinitions  = "<%= model->controltab %>"
                  filter          = "SERVER"
                  selectedRowIndex = "<%= model->selected_row %>"
                  onRowSelection  = "row_select"
                  sort            = "SERVER"
                  columnHeaderVisible = "TRUE"
                  visibleRowCount = "<%= model->ROW_COUNT %>"
                  iterator = "<%= iterator %>"     />

i guess somewhere (may be in oninputprocessing) you need to get the ref of <tab> to your model table .
<b> get reference of <tab> into model->table-> .</b>
i never tried anything like this, but i suggest you to try this.
Regards
Raja

Similar Messages

  • Problems with a table in PDF`S footer

    Dear sirs,
    We are having problems when trying to run a PDF with Adobe LiveCycle Designer tool.
    We are working with a PDF which is composed of a header, the main body and a footer. We have created a table (table1) at the footer and
    another one at the main body (table2). This last table (table2) may overflow therefore it will genarate two pages for our PDF.
    On both pages appear the header and the footer correctly but in the last page it does not write the data from the table included in the footer (table1).
    We have no problems with the table included in the main body
    In the attachments, I send you the screenshots of both pages in which I have marked in red the part where we have error.
    May you help us to solve our problem?
    Thanks in advance your help.
    Edited by: emgaitan on Mar 16, 2010 2:18 PM

    Wardell,
    Check the data in RSA3 for the extractor that you use to bring data .
    You must be using the data source 0CO_OM_CCA_09. Check the data and reconcile and you will get it.
    Let me know if you need anything else.
    Thanks
    Ravi Thothadri
    [email protected]

  • I am getting problem with internal table & work area declaration.

    I am working with 'makt' table ..with the table makt i need to work with styles attributes ..so i declared like this
    TYPES : BEGIN OF ty_makt,
             matnr TYPE makt-matnr,
             spras TYPE makt-spras,
             maktx TYPE makt-maktx,
             maktg TYPE makt-maktg,
             celltab TYPE lvc_t_styl,
           END OF ty_makt.
    DATA : i_makt TYPE TABLE OF ty_makt.
    DATA : wa_makt TYPE ty_makt .
        But end of program i need to update dbtable "makt"...i am getting problem with internal table & work area declaration.
    i think makt table fields mapping and internal table/work area mapping is not correct. so please help me to get out from this.

    Hi Nagasankar,
    TYPES : BEGIN OF TY_MATNR,
                  MATNR TYPE MAKT-MATNR,
                  SPRAS TYPE MAKT-SPRAS,
                  MAKTX TYPE MAKT-MAKTX,
                  MAKTX TYPE MAKT-MAKTG,
                  CELLTAB TYPE LVC_T_STYL,  " Its Working perfectly fine..
                 END OF TY_MAKT.
    DATA: IT_MAKT TYPE STANDARD TABLE OF TY_MAKT,
              WA_MAKT TYPE TY_MAKT.
    Its working perfectly fine. if still you are facing any issue post your complete code.
    Thanks,
    Sandeep

  • Problem with a table control

    Hi gurus,
    I´ve a problem with a table control. It has 3 columns which one is a checkbox.
    I can fill all fields but in the moment I mark the checkbox this line must be unwritable. How can I do it?
    Thanks for all
    Dani

    Assign a function code to the checkbox column....
    so when u check / uncheck any entry, PAI + PBO will be triggered....
    In the PBO during the loop of table control, check the checkbox field value. if it is 'X', make the row readonly
    by looping at screen and setting screen-input = 0 for rest of the columns.
    like ...
    LOOP AT tc_itab
           WITH CONTROL tc_test
           CURSOR tc_test-current_line.
       module set_row_readonly. " loop at screen and set input = '0' if checkbox is checked...
    ENDLOOP.

  • Problem with maintain table views SM30 Transaction

    Hello All,
    i have a problem with the table maintenance view SM30, it doesn't permit me to modify the rows in the table.
    we have added a field into the table and when i tried to change the table view from menu: Utilities ==> table maintenance generator==> change the system propose me a message that the screen 0001 will be deleted and recreated...but the system has deleted the screen and doesn't recreate it...in somewehere on internet we find that we should use the transaction SE55 menu:
    Environment==> modification ==> Maintenance screen ==> button Layout which open the tool Screen Painter and from that we have created our screen with 4 fields of our table...our result that the screen is created and i can see it from the SM30 transaction but i can't insert rows in the table...when i try to go to maintain table: menu: Utilities ==> Table maintenance generator to try if i can modify something the system give me a message: "set the compare flag dialog ZIV_DP_PLCHAR_LA"
    the ZIV_DP_PLCHAR_LA is the name of my table...
    can you give me some advices please how should i do to fix this problem to insert rows in table throughout the transaction
    SM30 "maintain table views: initial screen"
    if i want to delete the screen from the SE55 transaction to recreate it newly what should i do to take care about some options
    to have a new screen?
    thanks for all
    Bilal

    Hi
    First delete the old table maintainence generator.
    Now Recreate the screen and your table is good to go..
    These error messages come when we add new fields and different version of the table maintainence generator in database.

  • Problem with Pivot Table with Graph: Line Bar Combo

    Hello people!
    I have a problem with pivot table and line bar combo (all in the same view (pivot table))
    I have some measures and one dimension in my report.
    --------------measure1---measure2---measure3
    Dim A.1
    Dim A.2
    Dim A.3
    If I choose my graph line bar combo automatically choose "line" measure 3 (last measure in "Show Controls"). How can I do if I want my measure1 for line and I don't want modify my pivot table?
    Thank you very much!

    Ok, I'll explain my problem again. In my pivot table I add graph vision and I want in the same view (Pivot table). My graph is "Line Bar Combo" and I don't know how but the last of my measures belongs to right AXIS, if I change order of my measures I can see in my graph the measure that I want in my right axis BUT also it changes the order of my pivot table.
    This is my problem. I think that I can do that with different views but I lose my selector view to view graphic and my pivot table at the same time.

  • Problem with truncate table in procedure ora -00054

    hi do anybody know where is mistake ???
    the procedure has problem with truncate table
    ora - 00054: resource busy and acquire with NOWAIT specified
    ora - 06512 at "POVAPSYS.HMAN_P_REFRESH", line 6
    ora - 06512 at "POVAPSYS.POVAPSYS", line 6
    ora - 06512 at line 1
    this is my procedure....
    AS
    BEGIN
    execute immediate 'TRUNCATE TABLE hman_t_max';
    INSERT INTO hman_t_max SELECT * FROM hman_v_max;
    COMMIT;
    END;

    2.MAKE SURE THAT OTHER THAN YOU ANYBODY IS TRYING TO
    COMPILE AND RUN THE PROCEDUREShould he make sure that anybody is running the procedure?
    3.MAKE SURE THAT ANY PARALLEL QUERY IS RUNNING IN THE
    SERVER SIDE,THATS KEEPS THE RESOURCE BUSYShould he make sure any parallel query is running in the server side to keep the resource busy?
    Gita,
    I COULDN'T RESIST HAVING ONE SUGGESTION FOR YOU. Please look at the impact of your English in the reply before posting. Check if that sends reverse message!
    Cheers
    Sarma.

  • Problems with partition tables

    Hi all,
    I've got some problems with partition tables. The script at the bottom run but when I wanna insert some values it returns me an error
    (ORA-06550: line 1, column 30: PL/SQL: ORA-06552: PL/SQL: Compilation unit analysis terminated
    ORA-06553: PLS-320: the declaration of the type of this expression is incomplete or malformed
    ORA-06550: line 1, column 7: PL/SQL: SQL Statement ignored)
    and I can't understand why!
    There's something incorrect in the script or not?
    Please help me
    Thanks in advance
    Steve
    CREATE TABLE TW_E_CUSTOMER_UNIFIED
    ID_CUSTOMER_UNIFIED VARCHAR2 (27) NOT NULL ,
    START_VALIDITY_DATE DATE NOT NULL ,
    END_VALIDITY_DATE DATE ,
    CUSTOMER_STATUS VARCHAR2 (255)
    PARTITION BY RANGE (START_VALIDITY_DATE)
    SUBPARTITION BY LIST (END_VALIDITY_DATE)
    PARTITION M200909 VALUES LESS THAN (TO_DATE('20091001','YYYYMMDD'))
    (SUBPARTITION M200909_N VALUES (NULL), SUBPARTITION M200909_NN VALUES (DEFAULT)),
    PARTITION M200910 VALUES LESS THAN (TO_DATE('20091101','YYYYMMDD'))
    (SUBPARTITION M200910_N VALUES (NULL), SUBPARTITION M200910_NN VALUES (DEFAULT)),
    PARTITION M200911 VALUES LESS THAN (TO_DATE('20091201','YYYYMMDD'))
    (SUBPARTITION M200911_N VALUES (NULL), SUBPARTITION M200911_NN VALUES (DEFAULT)),
    PARTITION M200912 VALUES LESS THAN (TO_DATE('20100101','YYYYMMDD'))
    (SUBPARTITION M200912_N VALUES (NULL), SUBPARTITION M200912_NN VALUES (DEFAULT)),
    PARTITION M201001 VALUES LESS THAN (TO_DATE('20100201','YYYYMMDD'))
    (SUBPARTITION M201001_N VALUES (NULL), SUBPARTITION M201001_NN VALUES (DEFAULT)),
    PARTITION M201002 VALUES LESS THAN (TO_DATE('20100301','YYYYMMDD'))
    (SUBPARTITION M201002_N VALUES (NULL), SUBPARTITION M201002_NN VALUES (DEFAULT)),
    PARTITION M210001 VALUES LESS THAN (MAXVALUE))
    (SUBPARTITION M210001_N VALUES (NULL), SUBPARTITION M210001_NN VALUES (DEFAULT))
    ;

    Hi Hoek,
    the DB version is 10.2 (italian version, then SET is correct).
    ...there's something strange: now I can INSERT rows but I can't update them!
    I'm using this command string:
    UPDATE TW_E_CUSTOMER_UNIFIED SET END_VALIDITY_DATE = TO_DATE('09-SET-09', 'DD-MON-RR') WHERE
    id_customer_unified = '123' and start_validity_date = TO_DATE('09-SET-09', 'DD-MON-RR');
    And this is the error:
    Error SQL: ORA-14402: updating partition key column would cause a partition change
    14402. 00000 - "updating partition key column would cause a partition change"
    *Cause:    An UPDATE statement attempted to change the value of a partition
    key column causing migration of the row to another partition
    *Action:   Do not attempt to update a partition key column or make sure that
    the new partition key is within the range containing the old
    partition key.
    I think that is impossible to use a PARTITION/SUBPARTITION like that: in fact the update of "END_VALIDITY_DATE" cause a partition change.
    Do u agree or it's possible an update on a field that implies a partition change?
    Regards Steve

  • Problem with the table control BDC in FV60 transaction

    Hi All,
    I got the problem with the table control in FV60 transaction.
    This is working for 900 line items.After 900 line items it is giving the problem like it is 1000th line item.You can post only 999 line items.
    I know we can post only 999 line items,but in my file only 920 line items.
    Please give me solution,if anybody come across this situation.
    Thanks & regards,
    rakesh.

    Hello Rakesh ,
    your file may have only 920 line items , but based on those line items, SAP may create few more  new lines ( based on the clearing recon accounts , inter company transaction ...etc )...
    regards
    Prabhu

  • Problem with checkbox selection in Tableview

    Hi All
    I am using table view with 8 columns - in the last 4 columns i have checkboxes for user input - i have a strange problem - when the table has multiple entries - for the last column i can only select the checkbox on line 1 - and i cannot select the checkbox on the remaining entries below - but for the other colums with checkboxes this is not the case
    The selection mode for the table is no line selection - since the table is already displayed with input enabled fields - this is to reduce the no of clicks for user
    Can anyone point out what is going wrong - how can i fix this - what i am doing wrong ?
    Thanks
    Sen

    Hi
    When i click on the checkbox for the 2nd or 3rd rows of the last column - nothing happens - the checkox is still active but nothing happens -
    this is the tableview code
    <htmlb:tableView id              = "Detail"
                     design          = "ALTERNATING"
                     headerText      = "Header Text"
                     onNavigate      = "onMyNavigate"
                     emptyTableText  = "test"
                     onRowSelection  = "onMyRowSelection"
                     fillUpEmptyRows = "false"
                     footerVisible   = "true"
                     visibleRowCount = "5"
                     table           = "<%= DETAILTAB %>"
                     iterator        = "<%= iterator %>" >
    and this is the code for the last column
    <htmlb:tableViewColumn columnName         = "OBSOFLGICON"
                               width               = "3"
                               type                = "user"
                               horizontalAlignment = "CENTER"
                               title               = "Obs" >
          <htmlb:checkbox />
        </htmlb:tableViewColumn>
    Thanks
    Sen

  • Method GET_STATIC_ATTRIBUTES with generic table-structure

    Hi ,
    I am trying to select some rows of a web dynpro alv .
      LS_ALL-TABNAME = VAR_NAME_OF_TABLE.
      CREATE DATA LS_ALL-OBJECT TYPE TABLE OF (VAR_NAME_OF_TABLE).      "<<<<<
      INSERT LS_ALL INTO TABLE LT_ALL.
      LOOP AT LT_ALL INTO LS_ALL.
        ASSIGN LS_ALL-OBJECT->* TO <FS_TABLE>.                 "<<<<<
      ENDLOOP.
      LT_ELEMENTS = WD_THIS->DYN_NODE->GET_SELECTED_ELEMENTS( INCLUDING_LEAD_SELECTION = ABAP_TRUE ).
      LOOP AT LT_ELEMENTS INTO LR_ELEMENT.
        LR_ELEMENT->GET_STATIC_ATTRIBUTES( IMPORTING STATIC_ATTRIBUTES = <FS_TABLE> ).
      "coding...
      ENDLOOP.
    My problem: It's a generic web dynpro alv (with a dynamic context node) and i only have the tablename (and so it's structure) of the alv at runtime in a variable.
    I want to select some rows of this alv and get the data of the selected rows, so I try to work with field-symbols, but because of the move-corresponding in the coding of the method IF_WD_CONTEXT_ELEMENT~GET_STATIC_ATTRIBUTES...:
    method IF_WD_CONTEXT_ELEMENT~GET_STATIC_ATTRIBUTES .
      field-symbols:
        <values> type data.
      assign me->static_attributes->* to <values>.
      move-corresponding <values> to static_attributes.
    endmethod.
    ...i get the short-dump:
    German:
    Falscher Typ eines Operanden bei der Anweisung MOVE-CORRESPONDING.
    English:
    Wrong type of operands during the assignment MOVE-CORRESPONDING.
    So how can i get the structure of my generic table and do a move-corresponding with the method above?
    Many thanks in advance!
    Regards,
    Ludwig
    Edited by: Ludwig Heinz on Mar 13, 2008 9:45 AM

    Ok - but how can i make a declaration of dref_tab?
    my coding:
    TYPES: BEGIN OF TS_ALL,
      TABNAME TYPE DD02L-TABNAME,
      OBJECT  TYPE REF TO DATA,
    END OF TS_ALL.
    "dref_tab TYPE HASHED TABLE OF TS_ALL
    "     WITH UNIQUE KEY TABNAME,
      FIELD-SYMBOLS:
      <FS_LINE>  TYPE ANY,
      <FS_STRUCT> TYPE ANY,
    "<FS_TABLE> TYPE ANY TABLE.
      CREATE DATA LS_ALL-OBJECT TYPE (LF_TABLENAME).    
      INSERT LS_ALL INTO TABLE LT_ALL.
    "CREATE DATA dref_tab TYPE TABLE OF (LF_TABLENAME).
    "ASSIGN dref_tab->* TO <FS_TABLE>.
    LOOP AT LT_ALL INTO LS_ALL.
        ASSIGN LS_ALL-OBJECT->* TO <FS_STRUCT>.             
      ENDLOOP.
      LT_ELEMENTS = WD_THIS->DYN_NODE->GET_SELECTED_ELEMENTS( INCLUDING_LEAD_SELECTION = ABAP_TRUE ).
      LOOP AT LT_ELEMENTS INTO LR_ELEMENT.
        LR_ELEMENT->GET_STATIC_ATTRIBUTES( IMPORTING STATIC_ATTRIBUTES = <FS_STRUCT> ).
    "        append <FS_STRUCT> to <FS_TABLE>.
      ENDLOOP.
    syntax-error:
    "dref_tab" is not a datareference-variable.
    So how is the right declarion of "dref_tab" ?
    Many thanks - i've you can solve this - i think i can finish it
    Regards,
    Ludwig

  • Problem with the table view's _visibleBounds when used on a scroll view

    I've had numerous problems with getting a table view to work on a scroll view since the table view keeps resizing (http://discussions.apple.com/thread.jspa?threadID=2618816&tstart=0)
    I have created the views in IB. The scroll view is attached to the controller's view, and is assigned as the controller's view. The frame size of the scroll view is 320x436. I am manually setting the content size in code:
    UIScrollView* tempScrollView = (UIScrollView*) self.view;
    tempScrollView.contentSize = CGSizeMake(320, 720);
    The table view's frame's width/height is set to 280x88 in IB (i.e the size of two cells), and the header and footer are set to size 0.
    However, when I run the code, the table view is smaller, it is only 280x68. I have looked in the debugger, and the table view's _contentSize (of its scroll view) is 280x88; however, the _visibleBounds property is 280x68.
    I've tried looking into the documentation for the UITableView class, but can't find anything on the _visibleBounds property, or where it is being set and how to force it to the correct size.
    If anybody has any advice, I'd appreciate it.

    I can get around this problem by going to the scrollview which the tableview belongs to, and unchecking the Autoresize Subviews box.
    But if anybody knows about the _visibleBounds property, or the rules which are applied when resizing subviews, I'd be interested.

  • Problem with Generic datasource from function

    I developed generic datasource from function module.
    But I have problem with the select options.
    First one is order number  OBJECT_ID type char 10. When I input Object_ID = 45755 , no data selected.
    When input 0000045755, one data record selected.
    But I called functiion CONVERSION_EXIT_ALPHA_INPUT to conevet the input data. And I found  45755 was converted to 0000045755, but no record selected.
         LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'OBJECT_ID'.
            MOVE-CORRESPONDING L_S_SELECT TO L_R_OBJECT_ID.
            APPEND L_R_OBJECT_ID.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
      EXPORTING
        INPUT         = L_R_OBJECT_ID-high
      IMPORTING
       OUTPUT        = L_R_OBJECT_ID-high
             CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
      EXPORTING
        INPUT         = L_R_OBJECT_ID-low
      IMPORTING
       OUTPUT        = L_R_OBJECT_ID-low
          ENDLOOP.
    Another problem is CREATED_AT, which type is DEC 15,  how could I handle it ?  input is yyyymmdd, I tried to add '000000', but can't select any data.
    Thanks for any help.

    code is :
    FUNCTION ZACTIVITY_PLAN_PARTNER.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(I_REQUNR) TYPE  SRSC_S_IF_SIMPLE-REQUNR
    *"     VALUE(I_DSOURCE) TYPE  SRSC_S_IF_SIMPLE-DSOURCE OPTIONAL
    *"     VALUE(I_MAXSIZE) TYPE  SRSC_S_IF_SIMPLE-MAXSIZE OPTIONAL
    *"     VALUE(I_INITFLAG) TYPE  SRSC_S_IF_SIMPLE-INITFLAG OPTIONAL
    *"     VALUE(I_READ_ONLY) TYPE  SRSC_S_IF_SIMPLE-READONLY OPTIONAL
    *"     VALUE(I_REMOTE_CALL) TYPE  SBIWA_FLAG DEFAULT SBIWA_C_FLAG_OFF
    *"  TABLES
    *"      I_T_SELECT TYPE  SRSC_S_IF_SIMPLE-T_SELECT OPTIONAL
    *"      I_T_FIELDS TYPE  SRSC_S_IF_SIMPLE-T_FIELDS OPTIONAL
    *"      E_T_DATA STRUCTURE  ZACTIVITY_PLAN_PARTNER OPTIONAL
    *"  EXCEPTIONS
    *"      NO_MORE_DATA
    *"      ERROR_PASSED_TO_MESS_HANDLER
    Example: DataSource for table SFLIGHT
      TABLES: CRMD_ORDERADM_H.
    Auxiliary Selection criteria structure
      DATA: L_S_SELECT TYPE SRSC_S_SELECT.
      DATA:   BEGIN OF ACTIVITY,
                       OBJECT_ID       type CRMT_OBJECT_ID_DB,
                       PROCESS_TYPE    type CRMT_PROCESS_TYPE_DB,
                       OBJECT_TYPE     type CRMT_SUBOBJECT_CATEGORY_DB,
                       CREATED_BY      type CRMT_CREATED_BY,
                       CREATED_AT      type CRMT_CREATED_AT,
               END OF ACTIVITY.
      DATA: ZACTIVITY   LIKE TABLE OF ACTIVITY WITH HEADER LINE,
            Zorder   LIKE TABLE OF ZORDER_S WITH HEADER LINE,
            d_start type c length 15,
            d_end type c length 15
    Maximum number of lines for DB table
      STATICS: S_S_IF TYPE SRSC_S_IF_SIMPLE,
    counter
              S_COUNTER_DATAPAKID LIKE SY-TABIX,
    cursor
              S_CURSOR TYPE CURSOR.
    Select ranges
      RANGES: L_R_OBJECT_ID FOR CRMD_ORDERADM_H-OBJECT_ID,
              L_R_CREATED_AT FOR CRMD_ORDERADM_H-CREATED_AT,
              L_R_date for ZACTIVITY_PLAN_PARTNER-ZPLAN_DAT.
    Initialization mode (first call by SAPI) or data transfer mode
    (following calls) ?
      IF I_INITFLAG = SBIWA_C_FLAG_ON.
    Check DataSource validity
        CASE I_DSOURCE.
          WHEN 'ZACTIVITY_PLAN_PARTNER'.
          WHEN OTHERS.
            IF 1 = 2. MESSAGE E009(R3). ENDIF.
    this is a typical log call. Please write every error message like this
            RAISE ERROR_PASSED_TO_MESS_HANDLER.
        ENDCASE.
        APPEND LINES OF I_T_SELECT TO S_S_IF-T_SELECT.
    Fill parameter buffer for data extraction calls
        S_S_IF-REQUNR    = I_REQUNR.
        S_S_IF-DSOURCE = I_DSOURCE.
        S_S_IF-MAXSIZE   = I_MAXSIZE.
        APPEND LINES OF I_T_FIELDS TO S_S_IF-T_FIELDS.
      ELSE.                 "Initialization mode or data extraction ?
    First data package -> OPEN CURSOR
        IF S_COUNTER_DATAPAKID = 0.
          LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'OBJECT_ID'.
            MOVE-CORRESPONDING L_S_SELECT TO L_R_OBJECT_ID.
            APPEND L_R_OBJECT_ID.
         ENDLOOP.
    if  L_R_OBJECT_ID-option is initial.
      L_R_OBJECT_ID-option = 'EQ'.
      L_R_OBJECT_ID-sign ='I'.
      endif.
      CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
      EXPORTING
        INPUT         = L_R_OBJECT_ID-high
      IMPORTING
       OUTPUT        = L_R_OBJECT_ID-high
             CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
      EXPORTING
        INPUT         = L_R_OBJECT_ID-low
      IMPORTING
       OUTPUT        = L_R_OBJECT_ID-low
          LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'CREATED_AT'.
            MOVE-CORRESPONDING L_S_SELECT TO L_R_CREATED_AT.
            APPEND L_R_CREATED_AT.
          ENDLOOP.
          OPEN CURSOR WITH HOLD S_CURSOR FOR
          SELECT OBJECT_ID FROM CRMD_ORDERADM_H
                                  WHERE OBJECT_ID  IN  L_R_OBJECT_ID
                                  AND          CREATED_AT IN L_R_CREATED_AT    and
                                        PROCESS_TYPE EQ 'Z220'.
        ENDIF.                             "First data package ?
    Fetch records into interface table.
      named E_T_'Name of extract structure'.
        FETCH NEXT CURSOR S_CURSOR
                   APPENDING CORRESPONDING FIELDS
                   OF TABLE E_T_DATA
                   PACKAGE SIZE S_S_IF-MAXSIZE.
        IF SY-SUBRC <> 0.
          CLOSE CURSOR S_CURSOR.
          RAISE NO_MORE_DATA.
        ENDIF.
        S_COUNTER_DATAPAKID = S_COUNTER_DATAPAKID + 1.
      ENDIF.              "Initialization mode or data extraction ?
    ENDFUNCTION.

  • Problem with generics in general framework

    Hi,
    I've just started using generics and I've been able to solve most of my problems with type declarations etc, but I still have a few problems left.
    My current problem is in a class which has a map of classes which implements a generic typed interface (The interface is called Persister in the code below).
    The map is declared as:
    private Map<Class<?>, Persister<?>> persisters =
              new HashMap<Class<?>, Persister<?>>(); And the interface is declared as:
    interface Persister<T>My problem is that a method in the class which has the map should return a Collection of type T.
    Can that be done without supressing warnings?
    It's probably hard to understand what I mean (since I don't know the terminology) so here's a complete minimal example which illlustrates the problem. The problem is in the selectAll method in the DbFacade class.
    The lines:
         Persister persister = persisters.get(clazz);
         Collection<E> result = persister.selectAll(clazz);Needs to be altered but to what? (Or do I need to make more changes?)
    Thanks in advance
    Kaj
    ///////////////// Start of complete example
    import java.util.*;
    class ClientSample {
         public static void main(String[] args) {
              DbFacade facade = new DbFacade();
              //Works..
              Collection<Holiday> holidays = facade.selectAll(Holiday.class);
    class DbFacade {
         //Map with many different type of persisters,
         //one persister per class.
         private Map<Class<?>, Persister<?>> persisters =
              new HashMap<Class<?>, Persister<?>>();
         DbFacade() {
              persisters.put(Holiday.class, new HolidayPersister());
         //This is where I'm stuck
         //I don't want to add supresswarnings to this method, so what should I do?
         public <E> Collection<E> selectAll(Class<E> clazz) {
              //The following line gives:
              //Persister is a raw type. References to generic type
              //Persister<T> should be parameterized
              Persister persister = persisters.get(clazz);
              //The following line gives:
              //Type safety: The expression of type List needs unchecked
              //conversion to conform to Collection<E>
              Collection<E> result = persister.selectAll(clazz);
              return result;
    interface Persister<T> {
         List<T> selectAll(Class<T> clazz);
    abstract class AbstractPersister<T> implements Persister<T> {
    class HolidayPersister extends AbstractPersister<Holiday> {
         public List<Holiday> selectAll(Class<Holiday> clazz) {
              return null;
    class Holiday {
         //data
    }

    Well you can put in a type cast
    Persister<E> pesister = (Persister<E>) persisters.get(clazz);but you'll stil get a warning. Sometimes there's just no avoiding them. What, AFAIK, you can't tell the compiler is that each entry of the map contains a persister for the class mapped to it.
    All it knows that classes are mapped to Persisters.

  • Problem with ADF Table and doDML method.

    HI,
    I have a problem with ADF Trinidad Table. I have one search form and which i click on search button the result is coming it's working fine, And when i click on CreateInsert button to insert a new row it's adding after entering all the data into the table when i click on button on the page i am getting error like
    Messages for this page are listed below.
    Error     
    Missing mandatory attributes for a row with key oracle.jbo.Key[1 ] of type AppModule.CmSubscribersView1
    Error     
    Attribute Name in AppModule.CmSubscribersView1 is required
    Error     
    Attribute CreatedBy in AppModule.CmSubscribersView1 is required
    Error     
    Attribute CreationDate in AppModule.CmSubscribersView1 is required
    Here Created By and Creation Date are not available in the table i need to set these data from back end for that i have used doDML() method in the entity object and i written the logic but this method not even invoking as i couldn't able to see the logs in the server.
    protected void doDML(int operation, TransactionEvent e) {
    super.doDML(operation, e);
    System.out.println("^^^^^^^^^^^^^^^^66666Inside entity object^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ");
    // AppModuleImpl am=new AppModuleImpl();
    // Number userID= am.getUserId();
    //System.out.println("User id in the Entity Object Is: "+userID);
    oracle.jbo.domain.Date dt = new Date();
    if(operation ==DML_INSERT){
    EntityDefImpl cmSubscribers=CmSubscribersImpl.getDefinitionObject();
    CmSubscribersImpl newSubscribers=(CmSubscribersImpl)cmSubscribers.createInstance2(getDBTransaction(),null);
    Number n=new Number(1599);
    newSubscribers.setCreatedBy(n);
    newSubscribers.setCreationDate(dt);
    newSubscribers.setLastUpdateDate(dt);
    newSubscribers.setLastUpdatedBy(n);
    But still the same problem can any one help me inthis.
    Regards,
    Edited by: user5802014 on Aug 21, 2009 2:04 PM

    Hi,
    Modify your method to call super.doDML() after initialization of mandatory attributes as below:
    protected void doDML(int operation, TransactionEvent e) {
         oracle.jbo.domain.Date dt = new Date();
         if(operation ==DML_INSERT){
              //PRE-INSERT code begins     
           EntityDefImpl cmSubscribers=CmSubscribersImpl.getDefinitionObject();
           CmSubscribersImpl newSubscribers=(CmSubscribersImpl)cmSubscribers.createInstance2(getDBTransaction(),null);
           Number n=new Number(1599);
           newSubscribers.setCreatedBy(n);
           newSubscribers.setCreationDate(dt);
           newSubscribers.setLastUpdateDate(dt);
           newSubscribers.setLastUpdatedBy(n);
           //PRE-INSERT code ends
           super.doDML(operation, e);
           //POST-INSERT code if any
         }else
            super.doDML(operation, e);
    }Sireesha

Maybe you are looking for

  • Fix for broken tool cursors in PS Elements 7 with Windows 8.1?

    I have Photoshop Elements 7 and have been perfectly happy with it for editing photos/images as a hobby on my older Windows XP and Windows 7 PCs. I have no real need to upgrade to Photoshop Elements 12. I just installed  Windows 8.1 on my new Surface

  • Exchange 2013 SP1 - Error: Your request could not be completed

    When trying to log into the ECP I get an: Error Your request could not be completed.  Please try again later.    When I check the event viewer I get: WebHost failed to process a request.  Sender Information: System.ServiceModel.ServiceHostingEnvironm

  • Excise modvat account not defined for CAPE

    Hi Guru, Please help me. I am facing a problem in GR (MIGO) for import material. Import material PO with Asset  (A) account catg.was created and at the time of GR (MIGO). system gives error Excise modvat account not defined for CAPE transaction for e

  • Payment Wizard in  8.8

    Hi All, In 8.8 , can we have the option to have the Invoice rate on Payment wizard and not Today's rate. On 2007 we had the option to take the rate from invoice day but on 8.8 apparently it's not possible. Is it possible to use the exchange rate from

  • Application connection to  TimesTen In-Memory Database

    Hi All, We're in the planing of creating TimesTen In-Memory Database for our production databases.Now we're in testing phase,we made one TimesTen In-Memory Database for one test database. Now we don't want to put all database in memory, we've some se