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: 

Problem by uploading files via gui_upload with large files

Former Member
0 Kudos
2,770

I´m using gui_upload to upload files to the application server. When I´m trying to trasfer files bigger than 150MB I get the exception dp_out_of_memory.

1 ACCEPTED SOLUTION

Former Member
0 Kudos
766

Hi,

You can not run FM gui_upload in background. It's a Gui function.

Svetlin.

32 REPLIES 32

Former Member
0 Kudos
766

run it in background

regards

Former Member
0 Kudos
767

Hi,

You can not run FM gui_upload in background. It's a Gui function.

Svetlin.

0 Kudos
766

Use function module C13Z_FRONT_END_TO_APPL to upload data from Presentation server to application server.

0 Kudos
766

I cannot find such an function module on my system. maybe i should say, that I´m using Web AS 620.

0 Kudos
766

Try to use

OPEN DATASET <filepath>

READ DATASET <filepath> INTO <itab>.

CLOSE DATASET <filepath>.

loop the <itab>

TRANSFER f TO <filepath>.

regds

gv

0 Kudos
766

It doesn´t work. Open dataset can´t find the file.

OPEN DATASET file FOR INPUT IN TEXT MODE ENCODING DEFAULT.

IF sy-subrc = 0.

DO.

READ DATASET file INTO wa_s.

IF sy-subrc ' TYPE 'I' NUMBER 001 WITH 'Doesn´t work'.

ENDIF.

0 Kudos
766

can we run FM 'upload' or 'ws_upload' in background

regards

0 Kudos
766

You can't run in background.

0 Kudos
766

That´s true, you can´t run ws_upload in background, there is even a exception:

no_batch = 5

0 Kudos
766

thanks

Pat,

did u found any solution

regards

Message was edited by: Surpreet Singh Bal

0 Kudos
766

If the file size is big ask to your basis people to store the file in Application server. They can directly access the application server.

0 Kudos
766

Hi,

Copy the file to the application server and then use dataset stmt.

Svetlin

0 Kudos
766

Yes, I know. I do it this way by now. But that´s what i´m trying to avoid.

0 Kudos
766

Read this thread. It describes how you can use dataset to read from presentation server.

Svetlin

0 Kudos
766

Thanks for the link, but the solution is not applicable. The directory of the file isn´t a network share.

0 Kudos
766

Hi Patrick,

than two last options you can try:

- ask your basis to increase memory limit (it can easily go up to 1GB, if you have the hardware)

- split the file

But using GUI_UPLOAD requires dialog process -> you always will need as much memory (and some more) as your file has.

Only in batch a line by line execution is possible.

Regards,

Christian

0 Kudos
766

Hi Christian thanks for your respons.

the memory is enough large, else the exception SYSTEM_NO_ROLL would be raised. I´ve dp_out_of_memory.

spliting file is not an option for me, unless there is a function modul or a class method to do this.

0 Kudos
766

Hi,

I think that you should change these system parameters(RZ10):

ztta/roll_extension

ztta/max_memreq_MB

Look for relevent oss notes ( sample notes 563688, 425207)

Svetlin

0 Kudos
766

Hi Patrick,

I'm always getting a 'TVS_NEW_PAGE_ALLOC_FAILED'-dump. There current memory usage is inside, also a hint, which parameters have to be changed.

I think, you are in a similar situation. Have a look, if system parameter abap/heap_area_dia is your limit. There is also a parameter abap/heaplimit, which is limit for one workprocess. Probably this triggers your dump (but all based on my experience with unsuccessful new page allocation).

Maybe your 'no roll' dump is more linked to parameters ztta/roll_area - ask a basis expert / have a look in OSS.

Regards,

Christian

0 Kudos
766

Hi Patrick,

Do you want the data be written to application server or read data from application server? If your requirement is the first one then you open the file in OUTPUT mode. This mode opens the file if its already there and creates if not. Then you transfer the data from your internal table to this file using TRANSFER command.

The code you have written it to read data from application server but not to write data into it.

Please let me know your requirement.

Thanks

Vamsi

0 Kudos
766

hi vamsi,

i want to read data from dem presentation server (with gui_upload, ws_upload, ..., but these function modules can´t handle large files) and write it to the application server.

Message was edited by: Patrick Plattner

0 Kudos
766

Thanks for Sveltin, Wolfgang and Christian.

The basis is on the way to check your inputs.

Former Member
0 Kudos
766

Try to use dataset stmt. But in most of the cases, it works only on the aplication server.

Svetlin

Former Member
0 Kudos
766

hi, I think you can split the big file into pieces. And upload them into application server.

OPEN DATASET FNAME FOR APPENDING.

Then use this to connect the pieces, recover to the orignial one file.

Hope it will be helpful

thanks

Former Member
0 Kudos
766

Have a look on OSS-Note 872457.

Regards Wolfgang

Former Member
0 Kudos
766

Patrick - rather than gui_upload, can you use one of the FTP FMs? Or can basis FTP at the OS level?

Rob

0 Kudos
766

no, ftp is no allowed on the application server.

0 Kudos
766

Hi Patrick,

The issue is not with the upload function module, it is the internal table memory that is the issue. Looking at the size of the file, I am assuming that the number of records in the file are to the tune of 100 thousand. There is a basis setting for the roll size memory that you can try tweaking.

Just curious, why is the file so big? Do you need to run this periodically or just once? If it is an ongoing process, why are you trying to find a desktop upload functionality, compared to application server upload?

Regards,

Srinivas

0 Kudos
766

Nothing worked by us. We wrote to the sap directly and even they couldn't help us.

They're preparing a new oss message for gui_upload because of the problem with large files.

Thanks all for your help.

Regards,

Patrick

0 Kudos
766

Hi ,

a coollegue had the same problem with files >= 200 MB

-> SAP-OSS told him to increase his virtual memory on his PC

Andreas

0 Kudos
766

Hi,

maybe OSS-note 872457 was created corresponding to this discussion - just like Andreas had already experienced:

Solution

Basically, the front-end file modules are not intended for transferring large volumes of data. Instead, large files should be loaded directly from the application server by using OPEN DATASET. If the files can only be read by using gui_upload, you need to adjust the memory space restriction of the work process correspondingly.

Regards,

Christian

oliver_sviszt
Explorer
0 Kudos
766

This message was moderated.