Error in Expert Routine

Hello Please I need help, I applied expert routine in my transformation in BI 7.0 and i get error, this is the code i used
Data : wa_SOURCE_PACKAGE  type tys_SC_1.
    data : wa_RESULT_PACKAGE  type tys_TG_1.
    loop at SOURCE_PACKAGE into wa_SOURCE_PACKAGE .
      move wa_SOURCE_PACKAGE-/BIC/ER_ENUM to wa_RESULT_PACKAGE-/BIC/ER_ENUM.
      move wa_SOURCE_PACKAGE-/BIC/ER_EAGE to wa_RESULT_PACKAGE-/BIC/ER_EAGE.
      move wa_SOURCE_PACKAGE-/BIC/ER_ENAME to wa_RESULT_PACKAGE-/BIC/ER_ENAME.
      move wa_SOURCE_PACKAGE-/BIC/ER_ESEX to  wa_RESULT_PACKAGE-/BIC/ER_ESEX.
      wa_RESULT_PACKAGE-/BIC/ER_ESAL = '2000'.
      append RESULT_PACKAGE to wa_RESULT_PACKAGE.
    endloop.
Error Message that i get :
E:"WA_RESULT_PACKAGE" is not an internal table - the "OCCURS n"
specification is missing.
Please can someone assist me with a solution to this.

ERROR IN APPEND STATEMENT .
CHANGE IT TO
append WA_ RESULT_PACKAGE  to RESULT_PACKAGE.
WORK AREA SHOULD BE APPENDED TO RESULT_PACKAGE

Similar Messages

  • Error Stack in Expert Routine, Infos about Object Log

    Hi all,
    currently I try to find some information about using the error stack in combination with an expert routine. So far I know that I have to use the Object Log, which is already in place in my code for monitor messages.
    LOOP AT itab_input INTO wa_input.
    IF sy-subrc <> 0.
            CLEAR msg.
            msg-msgid = 'MY_CLASS'.
            msg-msgty = 'E'.
            msg-msgno = '002'.
            msg-msgv1 = v1.
            msg-msgv2 = v2.
            msg-msgv3 = v3.
            APPEND msg TO t_msg.
            " ??? Write wa_input to error stack???
            CONTINUE.
          ENDIF.
    ENDLOOP.
    Does somebody know how I could append wa_input to the error stack? Or does somebody have a good documentation about Object log?
    Thanks a lot!
    Nita

    Good Morning,
    thanks a lot for your input. I tried to implement this function, but I do not know where I could get the Segment Id from.
    Do you know what i_use_crosstab is used for? I think i_with_message should be set to 'X' if I want to write wa_input-record it to the error stack.
    CALL METHOD log->verify_record
              EXPORTING
                i_use_crosstab  = ''
                i_segid         = lv_segid
                i_record        = wa_input-record
                i_with_message  = 'X'
              RECEIVING
                r_skip          = lv_skip
              EXCEPTIONS
                too_many_errors = 1
                not_in_crosstab = 2
                OTHERS          = 3.
    From semantic point of view the coding should do following:
    - To avoid a second loop in my expert routine it should only check the current src record. If this is wrong, which I already determine in my coding, it should write the record in the error stack. If it is correct, it should check whether there are already records with the same semantic key in the error stack and if yes, add it also to it.
    - I assume that I have to delete this record manually from my src. package than.
    Cheers
    Nita

  • Arithmetical errors or conversion errors found in routine ROUTINE_0002 reco

    Dear Experts ,
    This morning with data load we got the following error message :
    " Arithmetical errors or conversion errors found in routine ROUTINE_0002 record xxxx ".
    This load is for a data mart.Not a standard extraction.
    load fails in update rules.No errors in transfer rules.
    Please advice.
    Thanks in advance.
    Regards,
    Arun
    Edited by: Arun Kumar Dara on May 6, 2008 1:11 PM

    Hi,
    I think this error due to claculation of some value, in the update rules just check the code.
    Check the values which comes from the source which may be trying to calculate with some junk values.
    The best way is to de-bug the update rules using the Erroneous value, use the Key field value of that particular record for de-bugging the update rules.
    Rgs,
    I.R.K

  • "Error for COM routine using application program (return code 1028514-)"

    Hello Experts,
    We have one issue in SAP SAP SCM 5.10.
    When we are accessing the SNP Planing book, Now a days every often we are getting kicked out of the Planning book
    with the error message "Error for COM routine using application program (return code 1028514-)"
    How to rectify this,..Please advice /suggest
    Regards,
    Ramesh

    Sorry, I copy the content as below:
    Error -28514
    Version Not Found
    You attempted to access an OMS version, the liveCache infrastructure to store a Simulation Version, which does not exist (any longer).
    On a productive system this error should only occur in exceptional situations because liveCache checks whether the simulation exists beforehand and returns an Error 17831 if this is not the case.
    Reasons (=exceptional situation) for an error -28514 are:
    a transactional simulation (Simulation Version) is older than liveCache parameter MaxRetentionTime (default: 8 hours). In this case, the OMS version (more precisely: the corresponding consistent view) can be deleted (asynchronously) by liveCache and an error -28514 will occur if the application tries to use the transactional simulation again.
    a transactional simulation (Simulation Version) is older than liveCache parameter MinRetentionTime (default: 1 hour) and the data area usage exceeds 90%. In this case, the OMS version (more precisely: the corresponding consistent view) can be deleted (asynchronously) by liveCache and an error -28514 will occur if the application tries to use the simulation again.
    If liveCache deletes an OMS version due to one of the reasons above, a corresponding notice can be found in liveCache's knlmsg file (cyclically overwritten!).
    Error -28833
    Error -28833 ("Consistent view has been cancelled") occurs instead of an error -28514, if the an OMS version is deleted while a parallel liveCache call is still using this OMS version.
    Malfunction Test
    If this error occurs during LCAPPS internal malfunction tests, it indicates that the preceeding provoked exception has not been handled correctly. During the handling of the provoked exception the OMS version is dropped automatically. As the malfunction test program catches the exception which would normally lead to a shortdump, it either has to recreate the current simulation in liveCache or to ensure that it is not used any more.
    Error 17831 does not occur in this situation, because the keyed object representing the simulation (OMS version) is not deleted along with the version and can therefore still be accessed.
    Best Regards,
    Ada

  • Error for COM routine using application program (return code 40,134)

    Hi,
    I am facing Error while loading P-book
    Error for COM routine using application program (return code 40,134)
    My system details are
    SC2 system is SCM 7.0 and support pack SAPKY70002
    i have checked following thing before posting it but dint helped.
    1) SAP Notes 863244, 944254 -Not relevant to my system.
    2) Checked Livecache performance.
    3) Checked application logs during the time of error
    4) Carry out livecache inconsistency check and check any errors.
    let me know your expert views on this.
    Regards.
    Sandeep K.
    Edited by: khaire sandeep on Jul 27, 2009 4:21 PM

    Hi Sandeep,
    If you have de-intialised the planning area and intialised agian the com routine errors will be washed out, but still it is surprising.
    i guess this is something with the version that we are using in the planning area should have some issues.
    i prefer you to run the re-oraganisation check for the vesion if not done earlier.
    /SAPAPO/TSLCREORG - Check LiveCache Time Series Data
    And please dont look at the issue only at planning area level, pls explore your circumstances at the whole planning areas and commom objects like Storage bucket profiles.
    Yarala

  • Error for COM routine using application program (return code 40,075)

    Hi Experts,
    I am facing the problem to save in the Forecast in interactive planning book after executing the univerate fcst.
    It is saying "Error for COM routine using application program (return code 40,075)" when i save it in interactive
    planning book.
    The is happening to only one product among in the list of selections in the selection profile.
    What could be the reason, what i have to do to save my forecast in interactive planning book.
    it is not showing any error message for other products in the selection profile.
    please help me

    Hello Bhushan,
    The problem may be becuase your forecast keyfigure has fixed values in it. After forecast, the new values will be different but it cannot be saved since the values in your forecast keyfigure is fixed. So please undo fixing from your forecast kefigure inorder for the new values to be saved. Also you can check the note 1437685 inorder to have warning message.
    Thanks and Regards,
    Nithin.

  • Error for COM routine using application program (Return Code 40301)

    Hi Experts,
    Currently we are working on SCM 5.1 version.
    We are facing one issue. When we are trying to save one particular KF the system through below error
    "Error for COM routine using application program (Return Code 40301)"
    But when we save other KFs then data save successfully.
    This may be resolve by running consitancy check but if the inconsistancy is the issue then it should impact all the KFs.
    Can anyone help me to find the correct reason & solution?
    Thanks & Regards
    Sujay

    Dear Sujay Joshi ,
    The COM ERROR 40.301 means that the key figure became negative although this is not permitted.
    You need to check the setting of the key figure in your planning area and ensure that you have setup the respective key figure(s) accordingly (not allow negative values).
    If you believe that the negative value is not correct you have to reinitialize the planning area, after correcting the same. Please do a backup of the planning area before reinitializing.
    Please refer to the following SDN Thread for more information about the COM ERROR 40.301.
    How to allow or not allow negative values in key figures for SNP
    Check Note 944254. Also check the KF for Sales history or Statistical Fcst. where the tick negative values not allowed should be there. Sometimes calulation of the Praportional factors also causes te negative values getting calculated for certain KF. You will have to do thorough research to ascertain where from the negative value are coming into the KF.To start with reading the note that I have mentione above.
    I hope this helps.
    Regards,
    Tibor

  • Find DTP name from expert routine

    Hi ,
    Currently we are finding out the DTP id(that has been triggered the current load) from the request number in the expert routine. But when we execute DTP in simulation mode, request number will become DTP_SIMULATION, in that case system is throwing error message when finding a DTP.
    Is there a way to find the DTP id from expert routine directly even DTP is executed in simulation mode?
    Regards,
    Ramesh
    Edited by: Ramesh R on Jul 6, 2010 1:45 PM

    Hi, In the expert routine, there is an Instance provided by SAP.
    It is
    p_r_request TYPE REF TO if_rsbk_request_admintab_view READ-ONLY.
    This has the method GET_DTP.
    Regards
    Nages

  • Sample source code for fields mapping in expert routine

    Hi All
    Iam writing the expert routine from dso to cube for example I have two fields in dso FLD1,FLD2
    same fields in infocube also ,can any body provide me sample abap code to map source fields to target fields in expert routine,your help will be heighly appreciatble,it's an argent.
    regards
    eliaz

    Basic would be ;
    RESULT_FIELDS -xxx = <SOURCE_FIELDS> -xxx
    you have the source fields as source, and result fields for as the target. In between you can check some conditions as in other routines of transformation.
    BEGIN OF tys_SC_1, shows your source fields ( in your case DSO chars and key figures)
    BEGIN OF tys_TG_1, , shows your result fields ( in your case Cube characteristics)
    Hope this helps
    Derya

  • Special chs in DSO expert routine

    Hello All,
    Data is being pulled from Transfer order DSO to GR DSO. The transformation uses a expert routine which pulls a field 'Requisitiner' from another DSO i.e. Purchase DSO.
    This expert routine brings invalid characters i.e. the field value which is in small letters.
    If I delete the request in GR DSO, I cannot edit the PSA and get the correct data, because basically the incorrect entries are coming from the expert routine.
    The real problem occurs when I try to activate data in GR DSO. The activation fails because of the requisitioner field value is in small letters.
    Do I have to make changes in the expert routine? OR is there another way to solve this.
    The loads are delta loads and requests from last 3-4 days have been failing to activate.
    Kindly inform.
    Regards,
    NK

    hi,
    use the ABAP statement convert to Upper case, or you can change the settings for the target infoobject (check the lowercase letter) in the Dev and transport it to the target system.
    Check with the users to see if they are ok with seeing lower case letters in the report, if yes then transporting the info object is a better option.
    regards,
    Arvind.

  • Coding Help in Expert Routine

    Dear Guru's
    We have a Expert Routine to Fill Data from a ODS to CUBE.
    i am facing problem in selection of DTP, When i mention CALDAY as eg:01.03.2009 - 31.03.2009.
    i Dont get only MARCH data in Cube but all the complete Data which is in ODS . i mean my Expert Routine  does not recognise my selection.
    Here is the Code
        DATA:
        BEGIN OF ls_ztwr_o13comp,
          calday          TYPE     /bi0/oicalday,
          co_area         TYPE     /bi0/oico_area,
          /bic/zcostcent  TYPE     /bic/oizcostcent,
          UNIT            TYPE     /bi0/oiunit,
          /bic/zacthours  TYPE     /bic/oizacthours,
          /bic/ztarhours  TYPE     /bic/oiztarhours,
          /bic/zprodvity  TYPE     /bic/oizprodvity,
          /bic/zcumachrs  TYPE     /bic/oizcumachrs,
          /bic/zcumbuhrs  TYPE     /bic/oizcumbuhrs,
          /bic/zprodcum   TYPE      /bic/oizprodcum,
        END OF ls_ztwr_o13comp,
        lt_ztwr_o13comp   LIKE TABLE OF ls_ztwr_o13comp
          WITH KEY co_area /bic/zcostcent calday UNIT,
        lt_ztwr_o13comp1  LIKE TABLE OF ls_ztwr_o13comp
          WITH KEY co_area /bic/zcostcent calday UNIT,
          wa_year TYPE n LENGTH 4,
          wa_month TYPE n LENGTH 2,
          wa_calmonth TYPE n LENGTH 6.
    $$ begin of routine - insert your code only below this line        -
        ... "insert your code here
        SELECT *
          FROM /bic/aztwr_o1300(ods)
          INTO CORRESPONDING FIELDS OF ls_ztwr_o13comp.
          COLLECT ls_ztwr_o13comp INTO lt_ztwr_o13comp.
        ENDSELECT.
        CLEAR ls_ztwr_o13comp.
        LOOP AT lt_ztwr_o13comp
         INTO ls_ztwr_o13comp.
          IF ls_ztwr_o13comp-/bic/zcumachrs = 0.
            ls_ztwr_o13comp-/bic/zprodcum = 0.
          ELSE.
            ls_ztwr_o13comp-/bic/zprodcum = ls_ztwr_o13comp-/bic/zcumbuhrs /
            ls_ztwr_o13comp-/bic/zcumachrs * 100.
          ENDIF.
          CLEAR:
          ls_ztwr_o13comp-unit,
          ls_ztwr_o13comp-/bic/ztarhours,
          ls_ztwr_o13comp-/bic/zacthours,
          ls_ztwr_o13comp-/bic/zcumbuhrs,
          ls_ztwr_o13comp-/bic/zcumachrs,
          ls_ztwr_o13comp-/bic/zprodvity.
          APPEND ls_ztwr_o13comp TO lt_ztwr_o13comp1.
        ENDLOOP.
        CLEAR ls_ztwr_o13comp.
        LOOP AT lt_ztwr_o13comp1
         INTO ls_ztwr_o13comp.
          COLLECT ls_ztwr_o13comp INTO lt_ztwr_o13comp.
        ENDLOOP.
        CLEAR:
        ls_ztwr_o13comp,
        lt_ztwr_o13comp1.
        LOOP AT lt_ztwr_o13comp
         INTO ls_ztwr_o13comp.
          wa_year = ls_ztwr_o13comp-calday(4).
          wa_month = ls_ztwr_o13comp-calday+4(2).
          CONCATENATE wa_year wa_month INTO wa_calmonth.
          MOVE-CORRESPONDING ls_ztwr_o13comp TO RESULT_FIELDS.
          RESULT_FIELDS-calmonth = wa_calmonth.
          RESULT_FIELDS-calyear = wa_year.
          APPEND RESULT_FIELDS TO RESULT_PACKAGE.
        ENDLOOP.
    Can any one please tell me where i should change the code, So that i get data for only those month which is mentioned in my DTP.
    Thanks in adv,
    Dev

    Hi Srinivas,
    You are selecting data from your DSO and then processsing it and then appending it in RESULT_PACKAGE.
    Now the data which will be selected because of the filter in the DTP will be in the internal table SOURCE_PACKAGE.
    So you should base your select on the DSO for all entries in Source_package. This will ensure you process only those records which are selected with the filter.
    Regards,
    Mansi

  • Currency Conversion in Expert Routine

    Hi
    We have written a expert routine for calculating some amount fields. Now these amount fields get local currency from the source. We need to change it to USD using a standard conversion type. This conversion type already exists. Now how can this be done in expert routine?
    Regards
    Merlin

    Hi Merlin,
    You could use Currency Translation with in BEx Query (It is available on conversion tab of the key figure properties) and use conversion type of USD on the key figure for Amout/Value
    regards
    Kulmohan

  • Technical fields in Expert Routine

    Hi,
    I need to write an Expert Transformation Routine to upload data into a DSO from a Generic Data Source.
    The Result Package has the following technical fields:
         Field: SID SID.
            SID           TYPE RSSID,
         Field: DATAPAKID Data packet number.
            DATAPAKID           TYPE RSDATAPID,
         Field: RECORD Data record number.
            RECORD           TYPE RSARECORD,
         InfoObject: 0RECORDMODE BW Delta Process: Update Mode.
            RECORDMODE           TYPE RODMUPDMOD,
    Can you please let me know what/ how should these fields be updated?
    Thanks,
    Sri.

    Hi,
    Check the below link for expert routine 
    http://wiki.sdn.sap.com/wiki/display/BI/ExpertRoutineinBI7Transformations
    Regards,
    Satya

  • Key Figues - SUMMATION in Expert Routine

    Hi All,
    Is there any to way to have to aggregation of Key Figures as "Summation" in Expert Routine??
    Please let me know if there is any work around for this..
    Thanks,
    Kapil

    This type of routine is only intended for use in special cases. You can use the expert routine if there are not sufficient functions to perform a transformation. The expert routine should be used as an interim solution until the necessary functions are available in the standard routine.
    Hi Kapil,
          You can use expert routine to program the transformation yourself without using the available rule types. You must implement the message transfer to the monitor yourself.
         If you have already created transformation rules, the system deletes them once you have created an expert routine.
         If the target of the transformation is a DataStore object, key figures are updated by default with the aggregation behavior Overwrite (MOVE). So i think expert routine aggregation does not work for transformation to the standard DSO.
    For more details:
    [https://forums.sdn.sap.com/click.jspa?searchID=13078965&messageID=2823817]
       Hope it helps you.
    Regards,
    Yokesh

  • Error in start routine

    Hello All,
    I am trying to activate a couple transformations for cubes in purchasing. I am getting the error in start routine. I checked the start routine.
    E:In PERFORM or CALL FUNCTION "ROUTINE_9998", the actual parameter
    "SOURCE_PACKAGE" is incompatible with the formal parameter
    "DATA_PACKAGE"
    I did see a couple threads in sdn regarding this. But wanted to make sure if those thing sapplyin my case. I am new to SAP BW hence want to make sure before touching the code.
    Can someone help me resolve this soon?
    Thanks,
    Dee.

    Hello Rakesh,
    METHODS
          start_routine
            IMPORTING
              request                  type rsrequest
              datapackid               type rsdatapid
            EXPORTING
              monitor                  type rstr_ty_t_monitors
            CHANGING
              SOURCE_PACKAGE              type tyt_SC_1
            RAISING
              cx_rsrout_abort.
        METHODS
          inverse_start_routine
            IMPORTING
              i_th_fields_outbound         TYPE rstran_t_field_inv
              i_r_selset_outbound          TYPE REF TO cl_rsmds_set
              i_is_main_selection          TYPE rs_bool
              i_r_selset_outbound_complete TYPE REF TO cl_rsmds_set
              i_r_universe_inbound         TYPE REF TO cl_rsmds_universe
            CHANGING
              c_th_fields_inbound          TYPE rstran_t_field_inv
              c_r_selset_inbound           TYPE REF TO cl_rsmds_set
              c_exact                      TYPE rs_bool.
    ENDCLASS.                    "routine DEFINITION
    $$ begin of 2nd part global - insert your code only below this line  *
    *The above part is in gray and i cannot change it.
      MONITOR_RECNO.
    Runtime attributs
        SOURCE_SYSTEM  = p_r_request->get_logsys( ).
    Migrated update rule call
      Perform routine_9998
      TABLES
        SOURCE_PACKAGE
      CHANGING
        l_abort.
    *-- Convert Messages in Transformation format
        LOOP AT MONITOR_RECNO INTO ls_monitor_recno.
          move-CORRESPONDING ls_monitor_recno to MONITOR_REC.
          append monitor_rec to MONITOR.
        ENDLOOP.
        LOOP AT MONITOR INTO ls_monitor.
          move-CORRESPONDING ls_monitor to MONITOR_REC.
          append monitor_rec to MONITOR.
        ENDLOOP.
        IF l_abort <> 0.
          RAISE EXCEPTION TYPE CX_RSROUT_ABORT.
        ENDIF.
    I dont know abap..can you please guide me with this

Maybe you are looking for

  • Forms 6.0 connectivity

    Can anybody suggest how to connect forms 6.0 with oracle 11g?

  • Problems with sound

    after some time sound card just stops working and I have to restart computer to have it working again aby idea

  • I cant create a book in iPhoto 5.0.4

    Hi all I cant create a book in iPhoto 5.0.4 - both the add new book button and the new book command in the menu are greyed out! I have rebooted, checked permissions, etc, etc...all the usual. Any thoughts? Thanks Rob

  • Use NAC Web Agent login with Ipad

    Hello Guys, I'm using NAC 4.8, and I'd like to login using NAC Web Agent on Ipad. When I'm trying to do that, I'm receiving a message on Ipad that I need to install Java Plug-In, but there is no JavaPlug-in available for Ipad. Does anyone know if the

  • [FIX] Getting hda_analyzer to work with python

    Hi everyone, I meant to put this up some time ago, so I apologise if this ends up as just noise but maybe this will help some people: If you have problems running hda_analyzer with the new python updates heres how to solve it (without downgrading): C