Entries in customised table

Hi,
   I created a customised table,in that user will enter H(hold)in a particular field.he will take the printout using the prog which i created and he will check whether the details are correct and if correct then they wants to change all the H to S.
   Here i dont know how to change all H to S .not that manually the user will go and change all the H to S.it should be automatically all H should change to S.
   Pls help me to solve the problem and give me in details would be more usefull for me.
Thanks,
Raj.

> Hi Rajendra
>
Hi Eswar,
   Even i put in end of the prog but it is not fetching the data.pls check help to solve the issue.
   below is the coding i used and i wants to use the code in   Form  1200_INPUT.
Database tables
TABLES : Z2006TMMAMEND.        "Amendment Notice Master Data
Internal tables
DATA : BEGIN OF ITAB OCCURS 0,
              ZMATNR  LIKE Z2006TMMAMEND-ZMATNR,
              ZMAKTX  LIKE Z2006TMMAMEND-ZMAKTX,
              ZAMEND  LIKE Z2006TMMAMEND-ZAMEND,
              ZMATKL  LIKE Z2006TMMAMEND-ZMATKL,
              ZCHARG  LIKE Z2006TMMAMEND-ZCHARG,
              ZWEEKS  LIKE Z2006TMMAMEND-ZWEEKS,
              ZDATES  LIKE Z2006TMMAMEND-ZDATES,
              ZSTATUS LIKE Z2006TMMAMEND-ZSTATUS,
       END OF ITAB.
******TO GET THE LAST AMENDMENT NO
DATA : BEGIN OF ITABLAST OCCURS 0,
             ZMATNR  LIKE Z2006TMMAMEND-ZMATNR,
             ZMAKTX  LIKE Z2006TMMAMEND-ZMAKTX,
             ZAMEND  LIKE Z2006TMMAMEND-ZAMEND,
             ZMATKL  LIKE Z2006TMMAMEND-ZMATKL,
             ZCHARG  LIKE Z2006TMMAMEND-ZCHARG,
             ZWEEKS  LIKE Z2006TMMAMEND-ZWEEKS,
             ZDATES  LIKE Z2006TMMAMEND-ZDATES,
             ZSTATUS LIKE Z2006TMMAMEND-ZSTATUS,
       END OF ITABLAST.
******FOR INPUT AMENDMENT NOTICES LISTING FOR YEAR WEEK NO***********.
DATA : BEGIN OF ITAB_H OCCURS 0,
             ZMATNR  LIKE Z2006TMMAMEND-ZMATNR,
             ZMAKTX  LIKE Z2006TMMAMEND-ZMAKTX,
             ZAMEND  LIKE Z2006TMMAMEND-ZAMEND,
             ZMATKL  LIKE Z2006TMMAMEND-ZMATKL,
             ZCHARG  LIKE Z2006TMMAMEND-ZCHARG,
             ZWEEKS  LIKE Z2006TMMAMEND-ZWEEKS,
             ZDATES  LIKE Z2006TMMAMEND-ZDATES,
             ZSTATUS LIKE Z2006TMMAMEND-ZSTATUS,
             ZAMENDL LIKE Z2006TMMAMEND-ZAMEND,
       END OF ITAB_H.
******FOR  AMENDMENT NOTICES UPDATE LIST***********
DATA : BEGIN OF ITAB_S OCCURS 0,
              ZMATNR  LIKE Z2006TMMAMEND-ZMATNR,
              ZMAKTX  LIKE Z2006TMMAMEND-ZMAKTX,
              ZAMEND  LIKE Z2006TMMAMEND-ZAMEND,
              ZMATKL  LIKE Z2006TMMAMEND-ZMATKL,
              ZCHARG  LIKE Z2006TMMAMEND-ZCHARG,
              ZWEEKS  LIKE Z2006TMMAMEND-ZWEEKS,
              ZDATES  LIKE Z2006TMMAMEND-ZDATES,
              ZSTATUS LIKE Z2006TMMAMEND-ZSTATUS,
              ZAMENDL LIKE Z2006TMMAMEND-ZAMEND,
              ZAMENDR LIKE Z2006TMMAMEND-ZAMEND,
        END OF ITAB_S.
DATA :I_ITABLAST LIKE ITABLAST OCCURS 0 WITH HEADER LINE.
DATA: WA         LIKE ITAB.
DATA: WA1        LIKE ITAB_H.
DATA: WA2        LIKE ITAB_S.
DATA: V_INT      TYPE INT4.
DATA: W_ZMATKL   LIKE Z2006TMMAMEND-ZMATKL.
DATA: W_ZWEEKS   LIKE Z2006TMMAMEND-ZWEEKS.
DATA: L_TABIX    LIKE SY-TABIX.
*SELECTION-SCREEN
selection-screen begin of block mysel with frame title text-001.
SELECT-OPTIONS : S_ZMATNR FOR Z2006TMMAMEND-ZMATNR,
                 S_ZWEEKS FOR Z2006TMMAMEND-ZWEEKS,
                 S_ZCHARG FOR Z2006TMMAMEND-ZCHARG,
                 S_ZAMEND FOR Z2006TMMAMEND-ZAMEND,
                 S_ZDATES FOR Z2006TMMAMEND-ZDATES.
selection-screen end of block mysel.
selection-screen begin of block mysel1 with frame title text-002.
PARAMETERS: C1 RADIOBUTTON GROUP R1,
            C2 RADIOBUTTON GROUP R1,
            C3 RADIOBUTTON GROUP R1,
            C4 RADIOBUTTON GROUP R1.
selection-screen end of block mysel1.
*selection-screen begin of block mysel2 with frame title text-003.
*SELECTION-SCREEN PUSHBUTTON /79(10) charly USER-COMMAND CONF.
*selection-screen end of block mysel2.
*INITIALIZATION.
MOVE 'CONF' TO charly.
START-OF-SELECTION
START-OF-SELECTION.
  IF C1 = 'X'.
    PERFORM 1100_DELETE.
  ELSEIF C2 = 'X'.
    PERFORM 1200_INPUT.
  ELSEIF C3 = 'X'.
    PERFORM 1300_UPDATE.
ELSEIF C4 = 'X'.
    PERFORM 1400_PRINT.
  ENDIF.
*END-OF-SELECTION.
TOP-OF-PAGE
top-of-page.
*& Form TOP_OF_PAGE
text
******FOR LIST OF DELETED AMENDMENT NOTICES***********
FORM TOP_OF_PAGEC1.
  SKIP.
  WRITE:/51 'MOTION SMITH CHART',  100 'Page :', 110 sy-pagno.
  SKIP.
  WRITE:/43 'LIST OF DELETED AMENDMENT NOTICES' ,100 'Date :', 110 sy-datum.
  SKIP.
ENDFORM.                               "TOP_OF_PAGEC1
******FOR INPUT AMENDMENT NOTICES LISTING FOR YESR WEEK NO***********
FORM TOP_OF_PAGEC2.
  SKIP.
  WRITE:/51 'MOTION SMITH CHART',  100 'Page :', 110 sy-pagno.
  SKIP.
  WRITE:/43 'INPUT AMENDMENT NOTICES LISTING' ,100 'Date :', 110 sy-datum.
  SKIP.
endform.                               "TOP_OF_PAGEC2
******FOR  AMENDMENT NOTICES UPDATE LIST***********
FORM TOP_OF_PAGEC3.
  SKIP.
  WRITE:/51 'MOTION SMITH CHART',  100 'Page :', 110 sy-pagno.
  SKIP.
  WRITE:/43 'AMENDMENT NOTICE UPDATE LIST' ,100 'Date :', 110 sy-datum.
  SKIP.
endform.                               "TOP_OF_PAGEC3
******FOR PRINT AMENDMENT LIST***********
FORM TOP_OF_PAGEC4.
  SKIP.
  WRITE:/51 'MOTION SMITH  AMENDMENT  LIST', 100 'Date :', 110 sy-datum, 140 'Page :', 150 sy-pagno.
  SKIP.
endform.                               "TOP_OF_PAGEC4
*&      Form  1100_DELETE
      text
-->  p1        text
<--  p2        text
FORM 1100_DELETE .
  NEW-PAGE.
  ULINE.
  PERFORM TOP_OF_PAGEC1.
  SELECT SINGLE ZMATKL INTO W_ZMATKL FROM Z2006TMMAMEND WHERE ZMATNR IN S_ZMATNR.
  WRITE:/ 'AGENCY CODE:', W_ZMATKL.
  SKIP.
  ULINE.
  SKIP.
  WRITE:/ 'CHART/PUBLICATION', 30 'DESCRIPTION', 61 '************* A  M  E  N  D  M  E  N  T  S *************'.
  SKIP.
  ULINE.
  SELECT * FROM  Z2006TMMAMEND INTO CORRESPONDING FIELDS OF TABLE ITAB
                                    WHERE ZMATNR IN S_ZMATNR
                                      AND ZWEEKS IN S_ZWEEKS
                                      AND ZCHARG IN S_ZCHARG
                                      AND ZAMEND IN S_ZAMEND
                                      AND ZDATES IN S_ZDATES
                                      AND ZSTATUS EQ 'D'.
  SORT ITAB BY ZMATNR.
  LOOP AT ITAB.
    WA = ITAB.
    AT NEW ZMATNR.
      V_INT = 1.
      WRITE:/ WA-ZMATNR(18), WA-ZMAKTX(40).
    ENDAT.
    IF V_INT >= 1 AND V_INT < 6.
      WRITE: WA-ZAMEND(11).
    ELSE.
      WRITE: /61 WA-ZAMEND(11).
      V_INT = 1.
    ENDIF.
    V_INT = V_INT + 1.
  ENDLOOP.
ENDFORM.                    " 1100_DELETE
*&      Form  1200_INPUT
      text
-->  p1        text
<--  p2        text
FORM 1200_INPUT .
  NEW-PAGE.
  ULINE.
SET PF-STATUS 'Z2006RMMAMEND'.
AT USER-COMMAND .
AT SELECTION-SCREEN.
  IF SY-UCOMM = 'CONF'.
      UPDATE Z2006TMMAMEND SET ZSTATUS = 'S'
                         WHERE ZSTATUS = 'H'.
  ENDIF.
  PERFORM TOP_OF_PAGEC2.
  SELECT SINGLE ZWEEKS INTO W_ZWEEKS FROM Z2006TMMAMEND WHERE ZWEEKS IN S_ZWEEKS.
  WRITE:/43 'FOR YEAR WEEK N0 :', W_ZWEEKS.
  SKIP.
  ULINE.
  SKIP.
  WRITE:/ 'AGENCYCODE', 15 'CHART NO', 30 'DESCRIPTION', 61 'YR/WK', 70 'LAST FAMD', 85 'LAMEND', 100 'AMENDMENT'.
  SKIP.
  ULINE.
**********TO GET THE INPUT AMENDMENT NOTICE LISTING FOR YEAR WEEK.
  SELECT * FROM  Z2006TMMAMEND INTO CORRESPONDING FIELDS OF TABLE ITAB
                                    WHERE ZMATNR IN S_ZMATNR
                                      AND ZWEEKS IN S_ZWEEKS
                                      AND ZCHARG IN S_ZCHARG
                                      AND ZAMEND IN S_ZAMEND
                                      AND ZDATES IN S_ZDATES
                                      AND ZSTATUS EQ 'H'.
***********TO GET THE LAST AMENDMENT NO.
  SELECT * FROM Z2006TMMAMEND INTO CORRESPONDING FIELDS OF TABLE ITABLAST
                                     WHERE ZMATNR  IN S_ZMATNR
                                       AND ZWEEKS  IN S_ZWEEKS
                                       AND ZSTATUS EQ 'S'.
  SORT ITABLAST DESCENDING BY ZWEEKS.
  LOOP AT ITAB.
    CLEAR ITABLAST.
    LOOP AT ITABLAST WHERE ZMATNR = ITAB-ZMATNR.
      EXIT.
    ENDLOOP.
    IF SY-SUBRC EQ 0.
      MOVE ITAB-ZMATKL TO ITAB_H-ZMATKL.
      MOVE ITAB-ZMATNR TO ITAB_H-ZMATNR.
      MOVE ITAB-ZMAKTX TO ITAB_H-ZMAKTX.
      MOVE ITAB-ZWEEKS TO ITAB_H-ZWEEKS.
      MOVE ITAB-ZAMEND TO ITAB_H-ZAMEND.
      READ TABLE ITABLAST WITH KEY ZMATNR = ITAB-ZMATNR.
      MOVE ITABLAST-ZAMEND TO ITAB_H-ZAMENDL.
      APPEND ITAB_H.
      CLEAR ITAB_H.
    ENDIF.
  ENDLOOP.
   SORT ITAB_H BY ZMATNR.
  LOOP AT ITAB_H.
    WA1 = ITAB_H.
    AT NEW ZMATNR.
      V_INT = 1.
      WRITE:/ WA1-ZMATKL(9),15 WA1-ZMATNR(18),30 WA1-ZMAKTX(40), 61 WA1-ZWEEKS(6),85 WA1-ZAMENDL.
    ENDAT.
    IF V_INT >= 1 AND V_INT < 3.
      WRITE: WA1-ZAMEND(11).
    ELSE.
      WRITE: /100 WA1-ZAMEND(11).
      V_INT = 1.
    ENDIF.
    V_INT = V_INT + 1.
  ENDLOOP.
ENDFORM.                    " 1200_INPUT
*&      Form  1300_UPDATE
      text
-->  p1        text
<--  p2        text
FORM 1300_UPDATE .
  NEW-PAGE.
  ULINE.
  PERFORM TOP_OF_PAGEC3.
  SKIP.
  ULINE.
  SKIP.
  WRITE:/ 'CHART/PUBLICATION', 30 'DESCRIPTION', 61 'AMENDMENT NO', 81 'AMENDMENT DATE', 100 'LAST AMENDMENT'.
  SKIP.
  ULINE.
  SELECT * FROM  Z2006TMMAMEND INTO CORRESPONDING FIELDS OF TABLE ITAB
                                    WHERE ZMATNR  IN S_ZMATNR
                                      AND ZWEEKS  IN S_ZWEEKS
                                      AND ZCHARG  IN S_ZCHARG
                                      AND ZAMEND  IN S_ZAMEND
                                      AND ZDATES  IN S_ZDATES
                                      AND ZSTATUS EQ 'S'.
    sort itab by zmatnr ZCHARG descending.
  loop at itab.
    l_tabix = sy-tabix.
    at new zmatnr.
      read table itab  index l_tabix.
      MOVE ITAB-ZMATKL TO ITAB_S-ZMATKL.
      MOVE ITAB-ZMATNR TO ITAB_S-ZMATNR.
      MOVE ITAB-ZMAKTX TO ITAB_S-ZMAKTX.
      MOVE ITAB-ZAMEND TO ITAB_S-ZAMEND.
      MOVE ITAB-ZWEEKS TO ITAB_S-ZWEEKS.
      MOVE ITAB-ZAMEND TO ITAB_S-ZAMENDR.
      l_tabix = l_tabix + 1.
      read table itab index l_tabix.
      MOVE ITAB-ZAMEND TO ITAB_S-ZAMENDL.
      APPEND ITAB_S.
      CLEAR  ITAB_S.
    ENDAT.
  ENDLOOP.
  LOOP AT ITAB_S.
    WA2 = ITAB_S.
    AT NEW ZMATNR.
      V_INT = 1.
      WRITE:/ WA2-ZMATKL,9'-',13 WA2-ZMATNR,27 WA2-ZMAKTX(40),63 WA2-ZAMENDR(15),83 WA2-ZWEEKS(6),103 WA2-ZAMENDL(15).
    ENDAT.
  ENDLOOP.
ENDFORM.                    " 1300_UPDATE
*&      Form  1400_PRINT
      text
-->  p1        text
<--  p2        text
FORM 1400_PRINT .
  NEW-PAGE.
  ULINE.
  PERFORM TOP_OF_PAGEC4.
  SELECT SINGLE ZMATKL INTO W_ZMATKL FROM Z2006TMMAMEND WHERE ZMATNR IN S_ZMATNR.
  WRITE:/ 'AGENCY CODE:', W_ZMATKL.
  SKIP.
  ULINE.
  SKIP.
  WRITE:/ 'CHART NUMBER', 20 'EDITION DATE', 45 'DESCRIPTION', 75 '************* A  M  E  N  D  M  E  N  T  S *************'.
  SKIP.
  ULINE.
  SELECT * FROM  Z2006TMMAMEND INTO CORRESPONDING FIELDS OF TABLE ITAB
                                    WHERE ZMATNR IN S_ZMATNR
                                      AND ZWEEKS IN S_ZWEEKS
                                      AND ZCHARG IN S_ZCHARG
                                      AND ZAMEND IN S_ZAMEND
                                      AND ZDATES IN S_ZDATES.
  SORT ITAB BY ZMATNR.
  LOOP AT ITAB.
    WA = ITAB.
    AT NEW ZMATNR.
      V_INT = 1.
      WRITE:/  WA-ZMATNR(18),20 wa-zcharg(10),35 WA-ZMAKTX(40).
    ENDAT.
    IF V_INT >= 1 AND V_INT < 6.
      WRITE: WA-ZAMEND(12).
    ELSE.
      WRITE: /76 WA-ZAMEND(12).
      V_INT = 1.
    ENDIF.
    V_INT = V_INT + 1.
  ENDLOOP.
ENDFORM.                    " 1400_PRINT
***********TO UPDATE THE CUSTOMISED TABLE WHEN USER PRESS THE CONF BUTTON
AT USER-COMMAND .
*AT SELECTION-SCREEN.
  IF SY-UCOMM = 'CONF'.
      UPDATE Z2006TMMAMEND SET ZSTATUS = 'S'
                         WHERE ZSTATUS = 'H'.
  ENDIF.

Similar Messages

  • Creating maintainance view for a customising table

    Hello Team,
    I have a scenario where we have to create a maintainance view for a standard customising table. But all changes to entries for customising tables will prompt for a transportable change request. How to switch off this prompt for change request? Please let me know your views on this.
    Thanks!

    create a maintainance view for a standard customising table
    Doing that wont be a good idea.
    If you only want to disable the transport request in a production system, then call transaction SOBJ. Give the name of the object = the maintenace view, set the "[Current Settings|http://help.sap.com/saphelp_glossary/en/35/2a2c6ad9685cd5e10000009b38f974/content.htm]" flag on. (eg. F-60 on V_T001B for "Posting Periods: Specify Time Intervals")
    Regards,
    Raymond

  • Customising table

    What is a customising table?

    Hi kartik,
    Customizing Tables
    Definition
    Customizing data is data created by customers when they customize their systems.
    The Customizing data in a customer client is not overwritten by a language import or an upgrade. Data is only imported into client 000. This is because Customizing data is the responsibility of the customer and cannot be overwritten by data from SAP. This also applies, without restrictions, to translations. However, customers may occasionally want to update their sample data and default settings with the latest translations from SAP.
    Only copy the clients from client 000 after all the required languages have been imported into client 000.
    You have the following options for updating a translation language for the Customizing settings of an existing customer client:
           1.      Using tools
           2.      Manual translation
    Using Tools
    As of Basis Release 3.1H, SAP provides the following tools for updating Customizing texts in clients other than 000:
    ·        Report RSREFILL
    The report RSREFILL compares the Customizing texts in the logon client with the SAP proposals in a reference language in client 000. If these texts are identical, their translations in the target language are copied from client 000 to the logon client. Data is inserted only; no existing data is overwritten.
    For more information on RSREFILL, see the documentation on the report, and SAP Note 48047.
    ·        Client maintenance with transaction SMLT
    This function works in the same way as the report RSREFILL, but does not make a comparison with a reference language. This means that more texts can be copied from client 000 to the target client.
    As with RSREFILL, Customizing data is inserted. No data is deleted or overwritten.
    You call RSREFILL as a report. You start the client maintenance function in transaction SMLT by choosing Language ® Special Actions ® Client Maintenance.
    SAP recommends that you use the language supplementation program, which now integrates the program RSREFILL and the client maintenance function.
    Combining RSREFILL or the client maintenance function with the language supplementation program has the following consequences for each client-specific Customizing table:
           1.      Any previous supplementation is reset.
           2.      RSREFILL or the client maintenance function is executed.
           3.      The table is supplemented.
    This avoids any problems caused by the order in which RSREFILL, the client maintenance function, and the language supplementation program run.
    Manual Translation
    The link between the translation environment and the Change and Transport System enables you to create translated Customizing texts in a particular system, record them in transport requests, and distribute them in the system landscape.
    Translate the remaining Customizing texts in transaction SE63. Record the translations in transport requests, and then use the Transport Management System (TMS) to distribute these requests in the system landscape.
    Integration of Address Maintenance for a Customizing Table
    Process Flow
    To automatically display address maintenance for a Customizing table, you have to carry out the following steps:
    Add a field for storing the address number to the table or the view. To do this, use domain AD_ADDRNUM. Based on the address domain, the system automatically generates an indicator (OBJH-OBJHASADDR) in transaction SE54 which specifies if the table or view contains an address or not.
    Maintain the TSADRV entry as described in Address Maintenance in Customizing.
    Use transaction SE54 to generate the table maintenance dialog for transaction SM30 (see also: BC - Generate Table Maintenance Dialog).
    Result
    Address maintenance is now an integral part of Customizing object maintenance.
    The address dialog box is called when you choose the address icon. If an address has already been maintained for the object, this address appears in either change or display mode on the dialog box.
    If no address has been maintained for the object or if no address exists for an address number, the system takes you automatically to the screen for creating an address.
    When you create an object, the system takes you automatically to the address dialog box at the time you release or save the data to prompt you to maintain the address. You can skip the address dialog box using the Cancel function.
    You can find examples of address maintenance in Customizing in transactions OX10 (plants) and OX02 (company codes). (See also: Customizing Objects Using Address Functionality).
    thanks
    sekhar
    reward me if usefull

  • About SE11- creating customising table

    Hi,
    I have created a client dependent data dictionary table using SE11 and its delivery class is 'C'- customising table, data class is APPL2 ( Organisation and customising) , Size category is 1( 550-2200) . I have also created its table maintenance generator.
    The questions while creating data records for the above table using SM30, the transport request created is 'Workbench' Type. For customising table, is it possible  to create customising request ?
    Regards,
    Vin

    If the number of entries to be transported are less , then goto SE10
    click on the new request button , then select the second radio button
    them placethe cursor on the task and clickon the display object list button,
    then give the fllowing entries , click on add button to add new entries
    R3TR TABU  <Table Name>
    double click on ur table name , in the next screen double click on input field
    click on add button to add new entries
    there give the entries to be transported , and atlast save the request

  • Unable to display data no entry in the table without using Model clause

    Hi,
    I've an urgent requirement described below :
    The previously posted Question has been answerted using Model Clause:
    Is there any way out to solve it without using Model clause:
    I've a table named as "sale" consisting of three columns : empno, sale_amt and sale_date.
    (Please ref. The table script with data as given below)
    Now if I execute the query :
    "select trunc(sale_date) sale_date, sum(sale_amt) total_sale from sale group by trunc(sale_date) order by 1"
    then it displays the data for the dates of which there is an entry in that table. But it does not display data for the
    date of which there is no entry in that table.
    If you run the Table script with data in your schema, then u'll see that there is no entry for 28th. Nov. 2009 in
    sale table. Now the above query displays data for rest of the dates as its are in sale table except for 28th. Nov. 2009.
    But I need its presence in the query output with a value of "sale_date" as "28th. Nov. 2009" and that of "total_sale" as
    "0".
    Is there any means to get the result as I require?
    Please help ASAP.
    Thanks in advance.
    Create table script with data:
    CREATE TABLE SALE
    EMPNO NUMBER,
    SALE_AMT NUMBER,
    SALE_DATE DATE
    SET DEFINE OFF;
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (100, 1000, TO_DATE('12/01/2009 10:20:10', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (100, 1000, TO_DATE('11/30/2009 10:21:04', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (100, 1000, TO_DATE('11/29/2009 10:21:05', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (100, 1000, TO_DATE('11/26/2009 10:21:06', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (100, 1000, TO_DATE('11/25/2009 10:21:07', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (200, 5000, TO_DATE('11/27/2009 10:23:06', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (200, 4000, TO_DATE('11/29/2009 10:23:08', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (200, 3000, TO_DATE('11/24/2009 10:23:09', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (200, 2000, TO_DATE('11/30/2009 10:23:10', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (300, 7000, TO_DATE('11/24/2009 10:24:19', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (300, 5000, TO_DATE('11/25/2009 10:24:20', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (300, 3000, TO_DATE('11/27/2009 10:24:21', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (300, 2000, TO_DATE('11/29/2009 10:24:22', 'MM/DD/YYYY HH24:MI:SS'));
    Insert into SALE
    (EMPNO, SALE_AMT, SALE_DATE)
    Values
    (300, 1000, TO_DATE('11/30/2009 10:24:22', 'MM/DD/YYYY HH24:MI:SS'));
    COMMIT;
    Any help will be needful for me
    Regards,

    select sale_date,sum(sale_amt) total_sale
    from
    select empno,0 sale_amt,(sale_date + ao.rn) sale_date
    from
    select empno,sale_amt,sale_date ,(t.nxt_dt - t.sale_date) diff
    from
    select empno
    ,sale_amt,trunc(sale_date) sale_date
    ,trunc(nvl(lead(sale_date) over (partition by 1 order by sale_date),sale_date)) nxt_dt
    from sale
    ) t
    where (t.nxt_dt - t.sale_date) >1
    ) rec,(select rownum rn from user_objects where rownum<=200) ao
    where ao.rn <=(rec.diff-1)
    union all
    select empno,sale_amt,trunc(sale_date) sale_date
    from sale
    group by sale_date
    order by 1;
    ~~~~Guess this will serve the purpose...
    Cheers Arpan

  • How to schedule a job poles for a entry in a table.

    Hi All ,
    I have to schedule a job which runs somw stored procedures only on sunday and monday of a week at 3 AM in the morning.
    The condition is that another application puts an entry into a table around 3 AM (some times before and some times late), now my should query
    count in the table and runs the procs , however once its done ,it should do it monday and then it should not run till next sunday.
    I have successfully created a job which keeps failing till it receives the entry and successfully runs the proc once the entry is there...
    However how to schedule this thing ..correctly I need help , I want this job to disable itself on sunday once the procs are run wake up next morning
    run again..and then next week ..
    Following is the job ,
    BEGIN
    -- Job defined entirely by the CREATE JOB procedure.
    DBMS_SCHEDULER.create_job (
    job_name => 'TESTING_FIRST_JOB',
    job_type => 'PLSQL_BLOCK',
    job_action => 'BEGIN SEODS.test_procedure_11292011(); END;',
    start_date => SYSTIMESTAMP,
    repeat_interval => 'freq=minutely; byminute=5',
    end_date => NULL,
    enabled => TRUE,
    comments => 'Job defined entirely by the CREATE JOB procedure.');
    end;
    =====================================================
    and following is the proc...
    create or replace
    procedure
    test_procedure_11292011 as
    var number;
    begin
    insert into SEODS.job_status
    values (systimestamp, 'JOB TEST_PROCEDURE_11292011 HAS STARTED SUCCESSFULLY');
    commit;
    SELECT COUNT(*)
    INTO var
    FROM seods.student_weekend_status;
    if var=0 then
    raise_application_error(-20101, 'There is no record in the student_weekend_status table');
    else
    all_realtime();
    end if;
    insert into SEODS.job_status
    values (systimestamp, 'JOB TEST_PROCEDURE_11292011 HAS FINISHED SUCCESSFULLY');
    commit;
    end;
    Thanks in advance , please help

    Hi,
    This is a known issue in the previous SQL Server version and has been fixed in SQL Server 2012. You should be able to set 90 minutes and the change would be saved in SQL Server 2012.
    http://connect.microsoft.com/SQLServer/feedback/details/346786/ssms-does-not-support-job-schedule-frequencies-greater-than-60-minutes
    Currently, you may schedule the job to occur every 1 hour or you may refer to the suggestion by Latheesh to get around this.
    Thank you for your understanding.
    Tracy Cai
    TechNet Community Support

  • How to delete the entries in CDCLS table

    Hi All,
    There is a potential issue with the size of table CDCLS on production system. We need to reduce or manage the amount of data in this table. CDCLS is a cluster table and cannot be reduced directly,
    So first we were reduced the entries in CDHDR and then from CDPOS tables.
    After that we tried to reduce the entries from CDCLS table through the program - RSSCD7RE, We are facing the error as - no data available and No active archive key was selected.
    Please help me out, how to proceed further in this task. Thanks in advance.

    Go to DB15 and see the archiving object.
    You can also use the archiving object CHANGEDOCU, please refer SAP documents for that.
    Transaction is
    SARA -> Archive object CHANGEDOCU
    Message was edited by:
            ANIRUDDHA DAS

  • How to delete the NULL entries in nest table

    Hi,
    After I used a loop and open/fetch cursor populated the object table
    I found there are random NULL entries in my object table (nest table)
    The data look like this
    NULL NULL           NULL
    NULL NULL           NULL
    123     03-MAY-04     ACTIVE
    NULL NULL           NULL
    NULL NULL           NULL
    234     21-MAY-04     ACTIVE
    NULL NULL           NULL
    345     11-MAY-04     ACTIVE
    NULL NULL           NULL
    How can I get rid of those NULL entries in my nest table? So it can become
    123     03-MAY-04     ACTIVE
    234     21-MAY-04     ACTIVE
    345     11-MAY-04     ACTIVE
    Additional info:
    create type myType as object
    (id NUMBER (10,0),
    eff_date date,
    status VARCHAR2(17)
    create type myNestTab as table of myType;
    I have tried Delete procedure in following two ways.
    Version 1:
    FOR i IN l_my_nest_tab.FIRST..l_my_nest_tab.LAST
    LOOP
    IF l_my_nest_tab(i).id IS NULL THEN
    l_curr_event_tb.DELETE(i);
                   END IF;                         
    END LOOP;
    Version 2:
    FOR i IN l_my_nest_tab.FIRST..l_my_nest_tab.LAST
    LOOP
    IF l_my_nest_tab(i) IS NULL THEN
    l_curr_event_tb.DELETE(i);
                   END IF;                         
    END LOOP;
    Both of them give me the error “no data found.” And only left me the first NOT NULL entry in the table.
    123     03-MAY-04     ACTIVE
    Thanks in avdance.

    Hi Vishnu,
    u can write a report program for this and in that use the event  :
    AT NEW <field-name> ( use primary key)
    your statements
    ENDAT
    for eg.
    loop at itab ( herfe itab must be of type of table for which u want to track new entries)
    at new matnr
    write:/ new record
    endat
    endloop.
    schedule this report in background to run in every 5 or 10 mins as per your requirement and hence changes can be tracked.
    regards
    Vinod

  • Can we change the fields of database unique index in a customised table?

    Hi all..
    I want to know that can we create or change or delete the database unique index of a customized table?
    In my case, there is a customised table with 4 primary keys with all the records to be maintained thru transaction code SM30.
    There is database unique index maintained for this table which has 2 fields. These 2 fields are out of the 4 primary fields of the table.I hope I have made myself clear!
    Now when I am trying to insert a record in the table it give me a short dump.( It says duplication of records is not allowed)
    The reason being that the new record that I am trying to insert in the database table has those 2 fields for which the unique index is maintained is the same as an already existing record.And the other two fields are different from the already existing record.So overall the combination of the 4 primary fields is different.
    Please tell me how shall I proceed now?
    I also tried to change the Unique index but it is asking me some kind of authrization(You are not authorized to make changes (authorization object S_DEVELOP)).Also I am not sure whether changing the unique index is feasible or not.?
    Thanks.

    hi
    I think you will not be able to do unique indexing withou the help of primary keys,so use all the primary keys into the table field selections  and and then create indexing otherwise dupilication of keys can occur. if you are not able to keep the primary keys then go for non unique key indexing,where you have to add the client field and the any keys of your wish.

  • Load the data from a transparent customised table in BW to an ODS

    Hi there,
    How can you load the data from a transparent customised table created in BW to an ODS.
    Many thanks.
    Sarah

    Hi,
    just create a generic datasource in rso2 for that table, replicate the datasource for source system 'myself', create a infosource and assign the new datasource to that infosource. Create a update rule from infosource to ods, create a infopackage and load the data.
    regards
    Siggi

  • Error message while running the payroll-no entry found in table t54c1

    Hi All,
    Im getting this error-error message while running the payroll-no entry found in table t54c1.What is the reason for this error?
    How doi solve it?

    Hello
    From the description of your problem above, your cumulation calender has not been generated for that month.
    Please take necessary action to ensure that calendar type is assigned to pay period in payroll area, by maintaining the payroll period which is represented by Date modifier and period modifier in view maintainance for table T54C1.
    Entries for this table are generated with the program RPUCTP10. (You should not have to create manual entries in this table.)
    Thanks and Kind Regards
    Ramana

  • Error in Sales Order idoc - No appropriate entry found in table ADRT

    Hello SAP Gurus,
    When I am retriggering a sales order idoc I am getting the following error message.
    No appropriate entry found in table ADRT
    How can I resolve this issue.
    Thanks,
    Narayan.

    Hello Lakshmipati,
    I have checked up the customer master. There was no communication method maintained for any of the customers.
    But even then the order idoc is triggered to our XI system.
    For the one that failed I have maintained the communication method and retriggered again. It had the same failure message.
    Any helpful thoughts is highly appreciated.
    Thanks & Regards,
    Narayan.

  • How to populate multiple entries to Bapi Table

    Hi all,
      How to populate multiple entries to Bapi Table.....
    Here is the code(in component controller)
      Z_Recr_Apply_Point_Input request = new Z_Recr_Apply_Point_Input(WDModelScopeType.TASK_SCOPE);
           int  size = wdContext.nodeApplicants().size();
                for(int i = 0 ; i < size ; i++)
                    String isselected = wdThis.wdGetContext().nodeApplicants().getElementAt(i).getAttributeAsText("Appl_Number");
                     if(isselected == "true")
                               com.models.veteranpoint.Zrecr_Aplno appid = new
                                    com.models.veteranpoint.Zrecr_Aplno();                                        
                                    appid.setAppl_Number(wdContext.nodeApplicants().
                                        getApplicantsElementAt(i).getAppl_Number());
                               request.addApplicants(appid);
    I want to pass the selected input field to bapi..
    Please tel me where i pass the input field...
    Please correct my code...
    Thanks & regards
    Mathi s

    Hi,
    Steps to insert multiple entries to BAPI table.
    1.Create an instance for BAPI input
    2.Bind the instance to the Node of the BAPI input
    3.Create instance of the Structure(BAPI table) to which input has to be added.
    4.Set the input values to the Structure instance.
    5.Add the instance to the BAPI input.
    6.Execute
    From the given example,I assume Z_Recr_Apply_Point_Input  is the BAPI Input and com.epiuse.us.recruitment.models.veteranpoint.Zrecr_Aplno as Structure
    Step 1:
    Z_Recr_Apply_Point_Input request = new Z_Recr_Apply_Point_Input(WDModelScopeType.TASK_SCOPE);
    Step 2:
    <b>wdContext.nodeZ_Recr_Apply_Point_Input.bind(request);</b>
    Steps 3 & 4:
    int size = wdContext.nodeApplicants().size();
    for(int i = 0 ; i < size ; i++)
    String isselected = wdThis.wdGetContext().nodeApplicants().getElementAt(i).getAttributeAsText("Appl_Number");
    if(isselected == "true")
    com.epiuse.us.recruitment.models.veteranpoint.Zrecr_Aplno appid = new
    com.epiuse.us.recruitment.models.veteranpoint.Zrecr_Aplno();
    appid.setAppl_Number(wdContext.nodeApplicants().
    getApplicantsElementAt(i).getAppl_Number());
    <b>wdContext.currentZ_Recr_Apply_Point_InputElement().modelObject().addRecr_Aplno(appid);</b>
    Step 5:
    <b>wdContext.currentZ_Recr_Apply_Point_InputElement().modelObject().execute();</b>
    Regards,
    Viji Priya

  • BPM question - Delete all entries in a table and Insert data

    Hello,
    I'm new to PI BPM and have this scenario to implement.
    I'm supposed to delete all entries in a table and then insert data to the same table.
    Is BPM necessary? If it is, what is the best practice to implement my scenario?
    I want to make sure that all entries were successfully deleted before insert data.
    How do I check if all entries in the table were deleted successfully before
    initiating insert.
    Thank you.
    -Won

    Hi Won,
    Yes, this is possible without BPM.
    You have to create 2 separate mappings, each for deleting & inserting the records.
    You will have 2 different Interface mappings as well.
    But in ID, create a single interface determination.
    In that, configure Deletion interface mapping first and in the second row, configure Insertion interface mapping.
    Please make sure that the parameter 'Mainain Order At runtime' is checked in interface determination.
    -Supriya.

  • Unable to create PR with Service Line & also no entry in ESLH table using

    Hi Experts,
    I am using BAPI => BAPI_REQUISITION_CREATE to create PR and it is successful to create PR but when I try to create PO is become fail (proably missing entry in ESLH table).
    Now my requirement is to create PR with Service Line and an entry in ESLH table (should be filled by SAP automatically). I have been passing the service related/account assigment tables into BAPI but still not working.
    Will you please give a solution to create PR with Service Line and also need an entry in ESLH table (its important to my req)?
    Also provide some input on Service Line, if possible(How to check Service Line for PR + Account Assignment to Service Line + etc.)?
    Note that: If I create PR manually then there have entry in ESLH and hence I can create PO.
    Definately the quick solution help me lot...
    Thanks
    AKG

    Hi Experts,
    I am using BAPI => BAPI_REQUISITION_CREATE to create PR and it is successful to create PR but when I try to create PO is become fail (proably missing entry in ESLH table).
    Now my requirement is to create PR with Service Line and an entry in ESLH table (should be filled by SAP automatically). I have been passing the service related/account assigment tables into BAPI but still not working.
    Will you please give a solution to create PR with Service Line and also need an entry in ESLH table (its important to my req)?
    Also provide some input on Service Line, if possible(How to check Service Line for PR + Account Assignment to Service Line + etc.)?
    Note that: If I create PR manually then there have entry in ESLH and hence I can create PO.
    Definately the quick solution help me lot...
    Thanks
    AKG

Maybe you are looking for