Skip to Content
author's profile photo Former Member
Former Member

ABAP How to add a line in one ODS from the start routine of another?


I want to increment a counter in an ODS when loading data into a cube.

The ODS looks like this :

0CALYEAR | 0FC_COUNT |some other charac.

The cube has a start routine. Everytime the start routine is called, I would like to update the ODS counter according to 0CALYEAR specified in the infopackage.

Does anybody has a clue on how to do that ?

Thank you very much


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Sep 25, 2006 at 04:33 PM

    What is the key of the ODS? 0CALYEAR??

    You can do an SQL 'UPDATE' at the end of the start routine to the active table of ODS. However, that is a bad idea.

    Do you really want to update it once for each start routine run (start routine can multiple times for the same load execution if there are multiple data packets)?

    If you do have to update the ODS this way, you should probably -

    - Create a Z table with ODS key and this no field;

    - update the Z table in the start routine

    - create a datasource on this z table and update the ODS with it.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      It might be easier to load through a z table.

      Have an ABAP program run after the successful run of load to cube (as next step in the process chain) which creates an entry in the z table, incrementing count by 1. Or if it is ok, this program can directly read the active table of ODS and update the same by incrementing the count using SQL (again, a bad idea to directly update the ODS table).

      I am not sure if this 'count' is going to be much useful. What if you back-out an incorrectly loaded request (will it decrease the count?), or, if it is a 'repeat delta' or 'repair full' kind of requests, how would you apply this logic? It might be easier to check the no of requests from the 'manage' tab of the cube, or, go to say table RSICCONT in SE16 and get the no of records for a cube (which will give you the no of requests added to it).

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.