cancel
Showing results for 
Search instead for 
Did you mean: 

Storage consumption of file GUI_UPLOAD & SCMS_BINARY_TO_XSTRING

VKK
Explorer
518

Dear experts,

In our business process, there is no Document Management System or external SAP Content server.

I am using GUI_UPLOAD function to attach a PDF file from user PC to SAP and convert the Binary content to XString through SCMS_BINARY_TO_XSTRING function.

Then, I move the XSTRING Hexadecimal content to a custom database table field (Type: RAWSTRING) & store it. Everything works fine.

  1. Now, I want to check the Memory storage consumption of my Production SAP system which has over 200 documents now. Please guide me how would I do it?
  2. Is there any better method than this to store user application files if there is no separate SAP content server?

View Entire Topic
roberto_forti
Contributor
0 Kudos

Hi Karthikeyan,

1. Regards comprehending memory storage with SAP BASIS.

2. Consider working with Application Server using SAP ABAP File Interface.

Example:

...

*Open DataSet files (Application Server)
  OPEN DATASET iv_file_path_s FOR OUTPUT IN BINARY MODE.

  IF sy-subrc NE 0.
*Exception
    RAISE ex_open_file_source.
  ENDIF.

*Read and transfer
  LOOP AT it_file[] INTO wa_file.

*Transfer source file
        TRANSFER wa_file TO iv_file_path_s.

        IF sy-subrc NE 0.
*Exception
          RAISE ex_transfer_file_source.
        ENDIF.

        CLEAR wa_file.
  ENDLOOP.

*Close DataSet source file
  CLOSE DATASET iv_file_path_s.

  IF sy-subrc NE 0.
*Exception
    RAISE ex_close_file_source.
  ENDIF.

Regards,