Skip to Content
0

data dictionary tmg doubt.

6 days ago

9

avatar image

hi expert:-

i have a custom table ZTEST_DT.

if i insert multiple record .duplicate recorded is deleted but that row is still not delete and insert to empty line check below image:

but i need to delete that row permanent...

This is Form Routin 05.Create New Record Code.

*----------------------------------------------------------------------*
***INCLUDE LZTEST_DTF01.
*----------------------------------------------------------------------*
FORM ZTEST_DATE.
  DATA: IT TYPE TABLE OF ZTEST_DT. "internal table
  DATA: WA TYPE ZTEST_DT.          "workarea
  SELECT * FROM ZTEST_DT INTO TABLE IT WHERE CCO = ZTEST_DT-CCO     
                                         AND PCO = ZTEST_DT-PCO.    
  SORT IT BY TDT DESCENDING. "TDT Trip To Date
  IF IT IS NOT INITIAL.
    LOOP AT IT INTO WA.
      IF WA-TDT < ZTEST_DT-FDT. "FDT Trip From Date.
        IF SY-SUBRC EQ 0.
          EXIT.
        ENDIF.
      ELSE.
        DELETE: ZTEST_DT.
        MESSAGE: 'Enter Correct date' TYPE 'E' DISPLAY LIKE 'I'.
        EXIT.
      ENDIF.
    ENDLOOP.
  ENDIF.
ENDFORM.  

If i Insert Same Value multiple Record. its inserted to DB table how to create Form Routine (01.before saving the data in the database.)and check insert multiple value after upload to DB Table.

tmg.jpg (37.3 kB)
tmg1.jpg (32.3 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

0 Answers