Skip to Content
author's profile photo Former Member
Former Member

FM to get path of Directory in AL11

Hi all,

My requirement goes like this,

I want to store all my table data on application server(AL11) . But I do not want to hard code the filepath as it can change.So it was decided to get it from the directory name.

So now I want to fetch the path of the folder and place my file there.

Is there any function module for getting the directory path or a table which stores the same?

I tried FM ' EPS_GET_DIRECTORY_PATH ' but it didnt give me the right result. 😔

Thanks in advance.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

7 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Mar 17, 2009 at 08:00 AM

    Hi,

    try below FMs

    F4_DXFILENAME_TOPRECURSION

    /SAPDMC/LSM_F4_SERVER_FILE

    thanks

    Vinod

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Thanks for your useful replies.

      The function modules suggested didnt work properly for me .. maybe the inputs were wrong.

      But after debugging I got the table in which these values are stored.

      For user defined directories in AL11 the table is USER_DIR.

  • Posted on Mar 17, 2009 at 08:00 AM

    Check this FM -RZL_READ_DIR

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 17, 2009 at 08:03 AM

    Hi,

    Use this FM.

    EPS_GET_FILE_ATTRIBUTES Pass in a filename and a path, and will return attributes for the file.

    Regards,

    NNR.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Mar 17, 2009 at 08:03 AM

    These are all good replies, however, wouldn't it be better to create logical file paths / names using transaction FILE?

    this depends on your requirement, but it might be worth to have a look at this.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 17, 2009 at 08:04 AM

    Hi ,

    Check the class CL_GUI_FRONTEND_SERVICES and its methods. "DIRECTORY_LIST_FILES" might server your purpose.

    Regards,

    Deepthi

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 13, 2009 at 12:56 PM

    I see that this has been answered, but I'm not sure I see the answer. We also have a similar problem of running on windows, but needing to review a directory to determine if files are present.

    An ABAP t-code AL11 would do what we want, but I'm having problems determining which calls are the correct calls. The table user_dir is a great start, but if you could provide more of the answer, that would be appreciated.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 13, 2016 at 02:40 PM

    Where used list shows: WSAF_READ_SAF_PATH

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.