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

Problem on 'SXPG_CALL_SYSTEM' function

Former Member
0 Likes
1,146

concatenate ' -classpath . -jar'

' /TEST/test.jar'

string_arg

INTO COMMAND_STR.

CALL FUNCTION 'SXPG_CALL_SYSTEM'

EXPORTING COMMANDNAME = 'ZJAVA'

ADDITIONAL_PARAMETERS = COMMAND_STR

TABLES EXEC_PROTOCOL = IT_BTCXPM

EXCEPTIONS

SECURITY_RISK = 1.

IF SY-SUBRC <> 0.

WRITE : 'Make directory error !'.

ENDIF.

I try using this function for execute external command.

and succesfully done before.

but the problem is sometimes 'string_arg' is exceed 255 charactor long.

ADDITIONAL_PARAMETERS type can hold only 255 charactor long.

is there any function can excute UNIX command with more than 255 charactor parameter?

or any other way to solve this problem?

thank you

1 ACCEPTED SOLUTION
Read only

andreas_mann3
Active Contributor
0 Likes
1,044

hi,

go to your admins, to write a corresponding unix-script.

if possible, you need only to call the command of the script.

Andreas

7 REPLIES 7
Read only

andreas_mann3
Active Contributor
0 Likes
1,045

hi,

go to your admins, to write a corresponding unix-script.

if possible, you need only to call the command of the script.

Andreas

Read only

0 Likes
1,044

HI.

there is no way to reduce string of parameter.

and what is call the command of the script?

can you show me example or useage?

thank you

Read only

0 Likes
1,044

Hi,

what is that Additinal parameter you pass it to The above Fm. i mean what it contains...

Regards

vijay

Read only

0 Likes
1,044

parameter is encoded password.

and that string are decoded by some jar(java) file.

there is no way to change that logic to ABAP logic.

should be decoded by only java.

that is problem.

Read only

0 Likes
1,044

Why can't you store that in a file, and pass it as an argument to the Command.

can it be done in that way..

Regards

Vijay

Read only

0 Likes
1,044

That makes problem too.

cause too many people access same time so server has overload to write and read and delete file even some times make error when write files.

I think need to solve other way...

Regards

Bae.

Read only

0 Likes
1,044

Hi,

Not Sure then how to solve.........,

if the String is more than 255 chars..

Regards

Vijay

Message was edited by: Vijay Babu Dudla