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

bdc

Former Member
0 Likes
367

hi abapers,

how to check whether the file is there or not in bdc(unix)?

1 ACCEPTED SOLUTION
Read only

varma_narayana
Active Contributor
0 Likes
347

Hi

For Local file

CALL The method CL_GUI_FRONTEND_SERVICES=>FILE_EXIST (Check it in SE24)

For application server file

OPEN DATASET P_FILE ....................

if sy-subrc ne 0.

Message 'File does not exist' type 'E'.

ENDIF.

<b><REMOVED BY MODERATOR></b>

Message was edited by:

Alvaro Tejada Galindo

2 REPLIES 2
Read only

varma_narayana
Active Contributor
0 Likes
348

Hi

For Local file

CALL The method CL_GUI_FRONTEND_SERVICES=>FILE_EXIST (Check it in SE24)

For application server file

OPEN DATASET P_FILE ....................

if sy-subrc ne 0.

Message 'File does not exist' type 'E'.

ENDIF.

<b><REMOVED BY MODERATOR></b>

Message was edited by:

Alvaro Tejada Galindo

Read only

Former Member
0 Likes
347

Hi,

You need to check using the OPEN DATASET, if the SY-SUBRC = 0 then the Fiels is there if not then the fiel is not there

Regards

Sudheer