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: 

move files from one folder to another folder at network level

amol_samte
Contributor
0 Kudos

HI,

     I have created one program in that files are moving from one folder to another in application server the path is SAP_REPORT/ED2/report/ptf. its working fine..

but same files are stored in same path at network folder path like -  \XYZ05\SAP_REPORT\ED2\report\ptf . My question is that is der is any abap level solution. to move files from one folder to another folder at network level..

1 ACCEPTED SOLUTION

amol_samte
Contributor
0 Kudos

is any one done this scenario...........

7 REPLIES 7

amol_samte
Contributor
0 Kudos

is any one done this scenario...........

0 Kudos

Hi Amol

Is this for Background Processing?

I've encountered a similar problem a while ago,

We had to move not just folders but to another system as well in the background

I achieved this by creating a script at OS level and executing it via SM69 as a batch job.

If it is not a batch job have you tried the normal gui_upload and download FM's.

Regards

Vic

0 Kudos

Create a OS level command in SM69... one for copy file .. and then paste file.

And then use FM "SXPG_COMMAND_EXECUTE" to run those commands with necessary parameters

0 Kudos

Hi Vic,

Thanks for ur reply,

actually i have seen threads about SXPG_COMMAND_EXECUTE  fm but i was not confidant for network path.

Yes its BG job...gui...fm or methods wont support ..

i think using fm SXPG_COMMAND_EXECUTE i can get the solution hope  so.

Thanks

Amol

0 Kudos

Hi Harshad,

     Can we create direct move file command...

0 Kudos

I think Yes.. but check the command for your OS. It supports the OS level command. if your OS has that command, then it should work

0 Kudos

Solved,

sample solution,

get all files using FM

EPS2_GET_DIRECTORY_LISTING

In application server file has no created date..so pick date from file...and remove except current one..by using CS.

and finally use

OPEN DATASET

TRANSFER

DELETE DATASET

CLOSE DATASET

Thanks,

Amol