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.
Showing results for 
Search instead for 
Did you mean: 

ABAP File renaming from *txt to *sik

Former Member
0 Kudos

Hi All

Please help me in finding root cause of below issue.

I am downloading the file on Application server,

as per the user requirement I want to download the file as .sik

as ext in the Application server

I have create command ZMV in unix and passing command to function module SXPG_CALL_SYSTEM

In production we are getting runtime error as MESSAGE_TYPE_UNKNOWN

In which sy-subrc =1 which means no permission.

For particular user I ma facing the issue in production.

we have tried solutions such as giving folder access rights to the file but still it is not working.


Active Contributor
0 Kudos

in dev-system you can try:

data: begin of tabl occurs 0,


end of tabl,

command type sting.

command = 'rm /home/.txt' /home.sik'

call 'SYSTEM' id 'COMMAND' field command

id 'TAB' field tabl-sys.


0 Kudos


I dont understand why some users are able to create file while doing sap transaction while others get dump.


0 Kudos


Here are some ideas:

- This may be obvious, but the operating system will check authorization of the generic SAP user (your admin should know and tell you more about it), not the specific SAP user executing the command.

So the problem should not be from one user or the other.

- A question: Do they write the path and file name? The error could come from here.

- in your example you use the 'rm' command. What happens if the user executes a second time and there is no file to remove?


Edited by: Phillip Morgan on Feb 13, 2012 5:32 PM

0 Kudos

call 'SYSTEM' id 'COMMAND' field command

id 'TAB' field tabl-sys.

Could be that the user is not having the authorisation to run the above command.I think it is related to

Authorisation Object S_C_FUNCT.

If I am not wrong the user need to have this set in his user profile.Basis guy can help you with more details if you can provide him the DISPALY AUHTORISATON FOR USER XXXX screenshot.



0 Kudos

Hi Anup,

rm will delete the file.

Check documention[for SXPG_CALL_SYSTEM: Run an External Command (Express Method)|] .

  EXEC_PROTOCOL = <Log> " In structure BTCXPM. Can
" contain STDOUT, STDERR

may give you more detailed information.