Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Delete data from application server

Former Member
0 Likes
1,412

Hi All.

I have created file in application by using OPEN DATA SET, I need to delete from application server after some validation , how to delete?

Please guide me.

Thanks in Advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,170

hi,

DELETE DATASET file.

Check for sy-subrc values for the proper execution of statement

Thanks

Sharath

9 REPLIES 9
Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,170

Hello,

After the validations , use DELETE DATASET statement.

It will delete the file specified in application server folder.

BR,

Suhas

Read only

Former Member
0 Likes
1,171

hi,

DELETE DATASET file.

Check for sy-subrc values for the proper execution of statement

Thanks

Sharath

Read only

Former Member
0 Likes
1,170

Hi ,

Code -


Delete Dataset w_file.

Regards

Pinaki

Edited by: Pinaki Mukherjee on Feb 12, 2009 12:25 PM

Read only

Former Member
0 Likes
1,170

hi,

In the above post 'file' is expected to be a character-type data object that contains the platform-specific name of the file.

Thanks

Sharath

Read only

Former Member
0 Likes
1,170

hi,

Delete dataset <datasetname>

this deletes the dataset in application server

regards

sarvesh

Read only

Former Member
0 Likes
1,170

Hi,

Refer to below link

[;

Regards

Natasha Garg

Read only

former_member404244
Active Contributor
0 Likes
1,170

Hi,

Use DELETE DATASET ..

Regards,

Nagaraj

Read only

Former Member
0 Likes
1,170

Hi,

DATA FNAME(60) VALUE 'file'.

OPEN DATASET FNAME FOR OUTPUT.

OPEN DATASET FNAME FOR INPUT.

IF SY-SUBRC = 0.

WRITE / 'File found'.

ELSE.

WRITE / 'File not found'.

ENDIF.

DELETE DATASET FNAME.

OPEN DATASET FNAME FOR INPUT.

IF SY-SUBRC = 0.

WRITE / 'File found'.

ELSE.

WRITE / 'File not found'.

ENDIF.

The output appears as follows:

File found

File not found

Use cane Also Use Function Modue: EPS_DELETE_FILE

Regards,

Gurpreet

Read only

Former Member
0 Likes
1,170

Solved. Thanks to all