Ansicht
Dokumentation

RSDRI_CUBE_WRITE_PACKAGE - Write data package into specific InfoCube

RSDRI_CUBE_WRITE_PACKAGE - Write data package into specific InfoCube

BAL_S_LOG - Application Log: Log header data   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

This module enables you to write data to an InfoCube. There is also an RFC-compatible version of this module: RSDRI_CUBE_WRITE_PACKAGE_RFC.

Class CL_RSDRI_INFOCUBE also allows you to write to an InfoCube. RSDRI... modules can also be used as wrappers for this class.

  • If the InfoCube to which you want to write to is a transactional InfoCube in planning mode, the data is written to an open planning request. This planning request will be used jointly by all write programs that use RSDRI_CUBE_WRITE_PACKAGE to write to the InfoCube. The system closes the planning request automatically and opens a new planning request once the open planning request reaches a certain size. There can only be one open planning request for each InfoCube.
If a write error occurs that will cause termination (see parameter i_mdata_check), the current package is not written at all. The open planning request remains in the state it had before it was called. No further external action is required to roll the data back.
  • If the InfoCube is not a transactional InfoCube, RSDRI_CUBE_WRITE_PACKAGE opens a new planning request. In this case, only one write program at a time can write to the APO request, since only one planning request can be open at a time. The opened planning request is closed again at the end of the RSDRI_CUBE_WRITE_PACKAGE call. This means that each RSDRI_CUBE_WRITE_PACKAGE call results in a new planning request, which is closed at the end.
If a write error occurs that will cause termination (see parameter i_mdata_check), the request that has just been opened has errors and is closed and deleted automatically.
  • If it is a transactional InfoCube in staging mode, an error is displayed. It is not possible to write to transactional InfoCubes in staging mode with RSDRI_CUBE_WRITE_PACKAGE. However, report SAP_CONVERT_NORMAL_TRANS can make a normal InfoCube from a transactional InfoCube and vice versa.

Update Task

An update task-compatible module can be used to call RSDRI_CUBE_WRITE_PACKAGE or its RFC-compatible variant RSDRI_CUBE_WRITE_PACKAGE_RFC using an update task-compatible module in the update task. There are a number of limitations however:

  1. Writing with delta determination is not possible in the update task.
  2. If the InfoCube has changed in the meantime, the InfoCube write program must be generated again. In the update task, this is only possible without a COMMIT, meaning that other write programs have to wait until the update task that has regenerated the write program has executed a COMMIT.
  3. If the structure of an InfoCube that delta determination has been authorized for has changed (see parameter i_delta), the staging table must also be regenerated as part of the write program generation. This is not possible in the update task and raises exception INHERITED_ERROR.
  4. Settings in the InfoCube, for example "automatic ROLLUP of a request" or "automatic COMPRESSION of a request, are not possible if the transactional request has been closed in the UPDATE task.
Scheduling a regular background job ensures rapid rollups or compressions.

To avoid these generation problems, we recommend calling function module RSDRI_INFOCUBE_GEN_PROGRAM for the InfoCube in question before the update task is called. This module regenerates the InfoCube write program and regenerates the staging table if necessary.


CALL FUNCTION 'RSDRI_INFOCUBE_GEN_PROGRAM'
   EXPORTING
     I_INFOCUBE = l_infocube
   EXCEPTIONS
     OTHERS     = 1.

Example

Notes

Further information





Parameters

C_T_DATA
E_RECORDS
E_REQUID
E_TS_MSG
I_CURR_CONVERSION
I_DELTA
I_INFOCUBE
I_MDATA_CHECK
I_NCUM_INIT

Exceptions

DUPLICATE_RECORDS
ILLEGAL_INPUT
INFOCUBE_NOT_FOUND
INHERITED_ERROR
NOT_TRANSACTIONAL
REQUEST_LOCKED
ROLLBACK_ERROR

Function Group

RSDRI_DBA

BAL_S_LOG - Application Log: Log header data   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.

Length: 5025 Date: 20240523 Time: 134007     sap01-206 ( 102 ms )