Application Development 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: 

How to get file perperties in Unix server

Former Member
0 Kudos

Dear All,

I want to get the file properties which is created in the SAP server and can be displayed using AL11.

My question is that: which BAPI can collect the infomation including generation time, size and so on.

Many thanks.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Thanks for all your answers.

But I couldn't get file created date or changed date. for example, the file created on 2005-11-16 15:01 shows '124461' in the field 'MTIME'.

pls help to get the relationshop between the two data. thanks very much.

My time zone is GMT+8.

7 REPLIES 7

Former Member
0 Kudos

In Unix the command to get the file properties is

ls -l <filename>

But I am not aware of the BAPI which gives the Info

Regards,

Usha

andreas_mann3
Active Contributor
0 Kudos

Hi Jerry,

look function group epsf:

e.g. fm EPS_GET_FILE_ATTRIBUTES

Andreas

former_member181962
Active Contributor
0 Kudos

Hi Jerry,

I don't know about a Bapi which would do this, but

the FM SUBST_GET_FILE_LIST will give you the properties of the files in a directory specified.

Regards,

Ravi

jayanthi_jayaraman
Active Contributor
0 Kudos

Hi,

Check this link.

http://www.sap-img.com/b1002.htm

This link discusses few things about UNIX.

Check it and reward points by cliking the star on the left of reply,if it helps you.

Former Member
0 Kudos

Hi,

Check out the following FMs:

EPS_GET_FILE_ATTRIBUTES

EPS_GET_DIRECTORY_LISTING to get files in a directory

SUBST_GET_FILE_LIST

Best Regards,

Anjali

Former Member
0 Kudos

Thanks for all your answers.

But I couldn't get file created date or changed date. for example, the file created on 2005-11-16 15:01 shows '124461' in the field 'MTIME'.

pls help to get the relationshop between the two data. thanks very much.

My time zone is GMT+8.

0 Kudos

Hi,

try that ext. perform :

   PERFORM P6_TO_DATE_TIME_TZ(RSTR0400) USING FILE-MTIME
                                               FILE-MOD_TIME
                                               FILE-MOD_DATE.

mtime is unix time : seconds since 01.01.1970

regards Andreas