Skip to Content
0
Former Member
Aug 02, 2007 at 07:01 AM

Small Doubt's.

17 Views

How to delete a row from the Z table, through an ABAP Program.?

How to clear all the data of table n insert new set of rows through an ABAP Program.?

This is the code i have return to insert the Values in Z-table.

REPORT ZMS_TELEPHONE.

TYPES : BEGIN OF ZTA_TELEPHONE1,

CU_ID TYPE ZTA_TELEPHONE-CU_ID,

CU_NAME TYPE ZTA_TELEPHONE-CU_NAME,

CU_ADDR TYPE ZTA_TELEPHONE-CU_ADDR,

END OF ZTA_TELEPHONE1.

DATA: I_ZTA_TELEPHONE TYPE STANDARD TABLE OF ZTA_TELEPHONE1,

W_ZTA_TELEPHONE TYPE ZTA_TELEPHONE1.

W_ZTA_TELEPHONE-CU_ID = 'C100'.

W_ZTA_TELEPHONE-CU_NAME = 'SOWRABH'.

W_ZTA_TELEPHONE-CU_ADDR = 'BANGALORE'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

W_ZTA_TELEPHONE-CU_ID = 'C200'.

W_ZTA_TELEPHONE-CU_NAME = 'UMASHANKAR'.

W_ZTA_TELEPHONE-CU_ADDR = 'DAVANGERE'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

W_ZTA_TELEPHONE-CU_ID = 'C300'.

W_ZTA_TELEPHONE-CU_NAME = 'PUSHPA'.

W_ZTA_TELEPHONE-CU_ADDR = 'TUMKUR'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

W_ZTA_TELEPHONE-CU_ID = 'C400'.

W_ZTA_TELEPHONE-CU_NAME = 'SHIVA'.

W_ZTA_TELEPHONE-CU_ADDR = 'ANANTHPUR'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

W_ZTA_TELEPHONE-CU_ID = 'C700'.

W_ZTA_TELEPHONE-CU_NAME = 'UMESH'.

W_ZTA_TELEPHONE-CU_ADDR = 'KERALA'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

W_ZTA_TELEPHONE-CU_ID = 'C600'.

W_ZTA_TELEPHONE-CU_NAME = 'BIKRAM'.

W_ZTA_TELEPHONE-CU_ADDR = 'BENGAL'.

APPEND W_ZTA_TELEPHONE TO I_ZTA_TELEPHONE.

MODIFY ZTA_TELEPHONE FROM TABLE I_ZTA_TELEPHONE.