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

file handling

Former Member
0 Likes
776

what is logical path and physical path in SAP? How to handle files from these?

what is logical path and physical path in SAP? How to handle files from these?

4 REPLIES 4
Read only

uwe_schieferstein
Active Contributor
0 Likes
697

Hello Madhavi

The function module <b>FILE_GET_NAME</b> convert a logical path into its corresponding physical path.

The advantage of using logical pathes within your applications is obivous:

If you need to change the physical path you just adjust it within transaction <b>FILE </b>yet no changes are required to your application.

Regards

Uwe

Read only

Former Member
0 Likes
697

Hi,madhavi rajulapati .

I think you should see this link , I'm sure it will help you.

http://help.sap.com/saphelp_40b/helpdata/en/2a/fa02b7493111d182b70000e829fbfe/content.htm

Regards,

feng.

Read only

Former Member
0 Likes
697

Hi,

Refer to the below mentioned Functio Module

Ws_upload Transfer files from the frontend to the application server.

Ws_download Transfer files from the application server to the frontend.

Ws_excel Download files at the frontend in excel format.

Ws_file_delete Delete file at the frontend.

CLPB_EXPORT Export files to clipboard

CLBP_IMPORT Copies clipboard into table

Please reward suitable points.

Regards,

IFF

Read only

Former Member
0 Likes
697

Hi

Hi

The function module FILE_GET_NAME convert a logical path into its corresponding physical path.

The advantage of using logical pathes within your applications is obivous:

If you need to change the physical path you just adjust it within transaction FILE yet no changes are required to your application.

http://help.sap.com/saphelp_erp2005vp/helpdata/en/25/ab3a57df3b11d189fc0000e829fbbd/frameset.htm

The file names that you use in ABAP statements for processing files are physical names. This means that they must be syntactically correct filenames for the operating system under which your R/3 System is running. Once you have created a file from an ABAP program with a particular name and path, you can find the same file using the same name and path at operating system level.

Since the naming conventions for files and paths differ from operating system to operating system, ABAP programs are only portable from one operating system to another if you use the tools described below.

To make programs portable, the R/3 System has a concept of logical filenames and paths. These are linked to physical files and paths. The links are created in special tables, which you can maintain according to your own requirements. In an ABAP program, you can then use the function module FILE_GET_NAME to generate a physical filename from a logical one.

Maintaining platform-independent filenames is part of Customizing. For a full description, choose Tools ® Business Engineer ® Customizing, followed by

Implement. projects ® SAP Reference IMG. On the next screen, choose Basis Components System Administration ® Platform-independent File Names.

For a more detailed description of the function module FILE_GET_NAME, enter its name on the initial screen of the Function Builder and choose Goto Documentation. On the next screen, choose Function module doc.

Another way of maintaining platform-independent filenames is to use the Transaction FILE. The following sections provide an overview of the transaction.

To create a logical filename, choose Logical filename definition, client-independent from the Navigation group box in Transaction FILE, then choose New entries. You define logical filenames

You can either define a logical filename and link it to a logical path (as displayed here), or you can enter the full physical filename in the Physical file field. In the latter case, the logical filename is only valid for one operating system. The rules for entering the complete physical filename are the same as for the definition of the physical path for the logical file. To display further information and a list of reserved words, choose Help.

If you link a logical path to a logical file, the logical file is valid for all syntax groups that have been maintained for that logical path. The filename specified under Physical file replaces the reserved word in the physical paths that are assigned to the logical path. To make the name independent of the operating system, use names that begin with a letter, contain up to 8 letters, and do not contain special characters.

Save your changes.

go to file transaction

clik on new entries

declare as below

Logical path ZFLIGHT

Name LOGICAL NAME FOR IDOC

and then go to right side syntax and grop there define os

-

-


Syntax group WINDOWS NT Microsoft Windows NT

Physical path /USR/SAP/