DTP selection criteria in start routine

Hi,
I have a code in the start routine where a variable lv_date gets the date from the DTP selections...
DATA : i_filter TYPE rsbk_th_range,
            wa_filter TYPE rsbk_s_range.
READ TABLE i_filter INTO wa_filter WITH  KEY
      fieldnm = 'ACT_GI_DTE '.
    IF sy-subrc EQ 0.
      lv_date = wa_filter-low.
   ELSE.
But now my problem is that we are no more giving the range, instead we are giving the single value. so now my code should read the single value ( lv_date = wa_filter-low) instead of the low value of the range. So how can I achieve this?
I mean my lv_date should get the single value populated in the DTP selections instead of the low value of the range values.
How can i achieve this??
Regards,
Shreesh.

Hi,
When you give range in any variable, it lower value is captured in low whereas upper value is captured in high of the variable.
Now that you are no more giving range but only single values, it would be enough if your code reads the data from low of the variable.

Similar Messages

  • Problems in Start Routine of Transfermations (DTP)

    Hi Abap OO Gurus,
    I am migrating the 3.x data source to BI 7.0 ,here I am getting problems in DTP especially in the start routine . we are using the SP10, pls see the below code  . I have fixed some code still I am getting problems  at the below loop statement .
    PROGRAM trans_routine.
          CLASS routine DEFINITION
    CLASS lcl_transform DEFINITION.
      PUBLIC SECTION.
        TYPES:
          BEGIN OF tys_SC_1,
         InfoObject: 0MPOINT Measuring point.
            MPOINT           TYPE /BI0/OIMPOINT,
         InfoObject: 0MDOC Measurement Document.
            MDOC           TYPE /BI0/OIMDOC,
         InfoObject: 0MPOBJ Object Number of Measuring Point Object.
            MPOBJ           TYPE /BI0/OIMPOBJ,
         InfoObject: 0MPTYP Type of Measuring Point.
            MPTYP           TYPE /BI0/OIMPTYP,
         InfoObject: 0PSORT Position Number of Measuring Point in Object (
    *Sort Field).
            PSORT           TYPE /BI0/OIPSORT,
         InfoObject: 0ASSEMBLY Assembly.
            ASSEMBLY           TYPE /BI0/OIASSEMBLY,
         InfoObject: 0ATINN Internal Characteristic Number.
            ATINN           TYPE /BI0/OIATINN,
         InfoObject: 0MDATE Date of Measurement.
            MDATE           TYPE /BI0/OIMDATE,
         InfoObject: 0TIME Time.
            TIME           TYPE /BI0/OITIME,
         InfoObject: 0DESIRSI Target Value for Measuring Point in SI Unit.
            DESIRSI           TYPE /BI0/OIDESIRSI,
         InfoObject: 0TVIND Target Value for Measuring Point Is Defined.
            TVIND           TYPE /BI0/OITVIND,
         InfoObject: 0MRMINI Lower Measurement Area Limit Is Defined.
            MRMINI           TYPE /BI0/OIMRMINI,
         InfoObject: 0MRMINSI Lower Meas. Limit or Min. Total Counter Read
    *ing in SI Unit.
            MRMINSI           TYPE /BI0/OIMRMINSI,
         InfoObject: 0MRMAXI Upper Measurement Area Limit Is Defined.
            MRMAXI           TYPE /BI0/OIMRMAXI,
         InfoObject: 0SIUNIT SI unit.
            SIUNIT           TYPE /BI0/OISIUNIT,
         InfoObject: 0CJUMPSI Counter Overflow Reading in SI Unit.
            CJUMPSI           TYPE /BI0/OICJUMPSI,
         InfoObject: 0PYEARSI Annual Performance in SI Unit.
            PYEARSI           TYPE /BI0/OIPYEARSI,
         InfoObject: 0CREATED_BY Created By.
            CREATED_BY           TYPE /BI0/OICREATED_BY,
         InfoObject: 0READSI Measured Value/Total Counter Reading in SI Un
    *it.
            READSI           TYPE /BI0/OIREADSI,
         InfoObject: 0READEU Measured Value in Document Entry Unit.
            READEU           TYPE /BI0/OIREADEU,
         InfoObject: 0RECDU Unit of Measurement for Document Entry.
            RECDU           TYPE /BI0/OIRECDU,
         InfoObject: 0CNTRRSI Counter Reading in SI Unit.
            CNTRRSI           TYPE /BI0/OICNTRRSI,
         InfoObject: 0CDIFFSI Counter Reading Difference in SI Unit.
            CDIFFSI           TYPE /BI0/OICDIFFSI,
         InfoObject: 0CAT_TYPE Catalog.
            CAT_TYPE           TYPE /BI0/OICAT_TYPE,
         InfoObject: 0CAT_GROUP Code group.
            CAT_GROUP           TYPE /BI0/OICAT_GROUP,
         InfoObject: 0FI_STATUS Processing Status.
            FI_STATUS           TYPE /BI0/OIFI_STATUS,
         InfoObject: 0DIM_ID Dimension Key.
            DIM_ID           TYPE /BI0/OIDIM_ID,
         InfoObject: 0CNTIND Measuring Point is Counter.
            CNTIND           TYPE /BI0/OICNTIND,
         InfoObject: 0EQUIPMENT Equipment Number.
            EQUIPMENT           TYPE /BI0/OIEQUIPMENT,
         InfoObject: 0FUNCT_LOC Functional Location.
            FUNCT_LOC           TYPE /BI0/OIFUNCT_LOC,
         InfoObject: 0CAT_CODE Code.
            CAT_CODE           TYPE /BI0/OICAT_CODE,
         InfoObject: 0MRMAXSI Upper Meas. Limit or Max. Total Counter Read
    *ing in SI Unit.
            MRMAXSI           TYPE /BI0/OIMRMAXSI,
         InfoObject: 0DOCAF Measurement Document Included for Associated T
    *ask.
            DOCAF           TYPE /BI0/OIDOCAF,
         InfoObject: 0RECORDMODE BW Delta Process: Update Mode.
            RECORDMODE           TYPE RODMUPDMOD,
         Field: RECORD.
            RECORD           TYPE RSARECORD,
          END   OF tys_SC_1.
        TYPES:
          tyt_SC_1        TYPE STANDARD TABLE OF tys_SC_1
                            WITH NON-UNIQUE DEFAULT KEY.
        DATA:
          p_check_master_data_exist
                TYPE RSODSOCHECKONLY READ-ONLY,
    *-    Instance for getting request runtime attributs;
        Available information: Refer to methods of
        interface 'if_rsbk_request_admintab_view'
          p_r_request
                TYPE REF TO if_rsbk_request_admintab_view READ-ONLY.
      PRIVATE SECTION.
        TYPE-POOLS: rsd, rstr.
    $$ begin of global - insert your declaration only below this line  -
    TABLES: ...
    DATA:   ...
    *constants: c_tabname type rstlogotab value '/BI0/MEQUIPMENT'.
    $$ end of global - insert your declaration only before this line   -
        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  *
    ... "insert your code here
    data: lt_data type ref to data.
    data: ls_data type ref to data.
    field-symbols: <G_T_0EQUIPMENT> type standard table.
    field-symbols: <G_S_0EQUIPMENT> type any.
    field-symbols: <FUNCT_LOC> type any.
    field-symbols: <DATEFROM> type any.
    field-symbols: <DATETO> type any.
    constants: c_tabname type rstlogotab value '/BI0/MEQUIPMENT'.
    $$ end of 2nd part global - insert your code only before this line   *
          CLASS routine IMPLEMENTATION
    CLASS lcl_transform IMPLEMENTATION.
          Method start_routine
          Calculation of source package via start routine
      <-> source package
      METHOD start_routine.
    *=== Segments ===
        FIELD-SYMBOLS:
          <SOURCE_FIELDS>    TYPE tys_SC_1.
        DATA:
          MONITOR_REC     TYPE rstmonitor.
    $$ begin of routine - insert your code only below this line        -
    fill the internal tables "MONITOR" and/or "MONITOR_RECNO",
    to make monitor entries
    In this start routine missing functional location for
    an equipment is added to a Data Package record, if it is available
        create data lt_data type table of (c_tabname).
        assign lt_data->* to <G_T_0EQUIPMENT>.
        create data ls_data type (c_tabname).
        assign ls_data->* to <G_S_0EQUIPMENT>.
        assign component 'FUNCT_LOC' of structure <G_S_0EQUIPMENT> to
        <FUNCT_LOC>.
        assign component 'DATE_FROM' of structure <G_S_0EQUIPMENT> to
        <DATEFROM>.
        assign component 'DATE_TO' of structure <G_S_0EQUIPMENT> to
        <DATETO>.
        CALL FUNCTION 'RSAU_READ_MASTER_DATA'
          EXPORTING
            I_IOBJNM                = '0EQUIPMENT'
            I_FLG_WHOLE_TABLE       = 'X'
          IMPORTING
            E_TABLE                 = <G_T_0EQUIPMENT>
          EXCEPTIONS
            READ_ERROR              = 1
            NO_SUCH_ATTRIBUTE       = 2
            WRONG_IMPORT_PARAMETERS = 3
            CHAVL_NOT_FOUND         = 4
            OTHERS                  = 5.
        CASE SY-SUBRC.
          WHEN 0.
            LOOP AT <G_T_0EQUIPMENT> INTO <G_S_0EQUIPMENT>.
              IF <FUNCT_LOC> IS INITIAL.
                DELETE <G_T_0EQUIPMENT>.
              ENDIF.
    master data collected and condensed
            ENDLOOP.
            <b>LOOP AT SOURCE_PACKAGE ASSIGNING <SOURCE_FIELDS>.
              IF ( SOURCE_PACKAGE-FUNCT_LOC IS INITIAL ) AND
              ( SOURCE_PACKAGE-EQUIPMENT IS NOT INITIAL ).
                READ TABLE <G_T_0EQUIPMENT> WITH KEY
                ('EQUIPMENT') = SOURCE_PACKAGE-EQUIPMENT INTO <G_S_0EQUIPMENT>
                IF SY-SUBRC = 0.
                  IF ( SOURCE_PACKAGE-MDATE >= <DATEFROM> )
                  AND ( SOURCE_PACKAGE-MDATE <= <DATETO> ).</b>* record for equipment exists and valid
                    SOURCE_PACKAGE-FUNCT_LOC = <FUNCT_LOC>.               MODIFY SOURCE_PACKAGE.
                  ENDIF.
                ENDIF.
              ENDIF.
            ENDLOOP.
          WHEN 4.
    master data is not (yet) loaded
          WHEN OTHERS.
    problem occured, output as warning
            MONITOR-MSGID = SY-MSGID.
            MONITOR-MSGTY = 'W'.
            MONITOR-MSGNO = SY-MSGNO.
            MONITOR-MSGV1 = SY-MSGV1.
            MONITOR-MSGV2 = SY-MSGV2.
            MONITOR-MSGV3 = SY-MSGV3.
            MONITOR-MSGV4 = SY-MSGV4.
            APPEND MONITOR.
        ENDCASE.
    if abort is not equal zero, the update process will be canceled
    DEL  :ABORT = 0.
    Please adjust the syntax manually.
        - Automatically replaced: COMM_STRUCTURE with SOURCE_FIELDS
        - Included the new Exception Handling (instead of ABORT)
    $$ end of routine - insert your code only before this line         -
      ENDMETHOD.                    "start_routine
          Method inverse_start_routine
          This subroutine needs to be implemented only for direct access
          (for better performance) and for the Report/Report Interface
          (drill through).
          The inverse routine should transform a projection and
          a selection for the target to a projection and a selection
          for the source, respectively.
          If the implementation remains empty all fields are filled and
          all values are selected.
      METHOD inverse_start_routine.
    $$ begin of inverse routine - insert your code only below this line-
        ... "insert your code here
    $$ end of inverse routine - insert your code only before this line -
      ENDMETHOD.                    "inverse_start_routine
    ENDCLASS.                    "routine IMPLEMENTATION
    here I am getting the error like ""SOURCE_PACKAGE" is a table without a header line and therefore has no component called "FUNCT_LOC". I tried many ways to fix this problem.
    Could you some kind soul educate how to fix the problem .
    Thanks in advacne ,RP.

    Since the MONITOR is a table without header-line, u can no longer use it as a workarea for record entry. You can use MONITOR_REC defined in the data-section of this method to fill in the record and then append it to the table.
    MONITOR-MSGID = SY-MSGID.
    MONITOR-MSGTY = 'W'.
    MONITOR-MSGNO = SY-MSGNO.
    MONITOR-MSGV1 = SY-MSGV1.
    MONITOR-MSGV2 = SY-MSGV2.
    MONITOR-MSGV3 = SY-MSGV3.
    MONITOR-MSGV4 = SY-MSGV4.
    APPEND MONITOR.
    has to be replaced with
    clear MONITOR_REC.
    MONITOR_REC-MSGID = SY-MSGID.
    MONITOR_REC-MSGTY = 'W'.
    MONITOR_REC-MSGNO = SY-MSGNO.
    MONITOR_REC-MSGV1 = SY-MSGV1.
    MONITOR_REC-MSGV2 = SY-MSGV2.
    MONITOR_REC-MSGV3 = SY-MSGV3.
    MONITOR_REC-MSGV4 = SY-MSGV4.
    APPEND MONITOR_REC to MONITOR.

  • Start Routine Lookup!

    Hi
    How to write a lookup in Start Routine to calling customer table. we are maintains values in custom table.
    i am
    Regds,DS

    Hi,
    You simply need to create an internal table of type customer table in start routine global declaration part.
    After that you will have to populate that internal table using select query in start routine. e.g.
    SELECT *
    FROM  XYZ
    into table it_xyz
    where key1 = 'AB'. etc.
    In this case XYZ is customer table and it_xyz is internal table. Once values are available in internal table you can use them in field routine or start routine as per the need.
    Regards,
    Durgesh.

  • Internal table on Start Routine

    Hello
    I have 5 key figures. They have an standard routine with a select statement. Basically they have to read an external DSO and get some fields values.
    As all of them have the same SELECT statement I think it would be better to replace this with a select in the Start Routine, in order to improve performance. But unfortunatelly I'm not an abap programmer.
    How could this be replaced in the Start routine ?
    select single EXRATEXACC DOC_CURRCY NETVAL_INV
          into (h_rate, h_dcurr, h_inv)
          from /bic/azsdbiio100
           where BILL_NUM eq SOURCE_FIELDS-/BIC/ZREFDOC
           and BILL_ITEM eq SOURCE_FIELDS-/BIC/ZREFDOCLN
           and COMP_CODE eq SOURCE_FIELDS-COMP_CODE.
      if sy-subrc ne 0. " Not found
            select single EXRATEXACC DOC_CURRCY NETVAL_INV
            into (h_rate, h_dcurr, h_inv)
            from /bic/azsdbiio100
             where DOC_NUMBER eq SOURCE_FIELDS-DOC_NUMBER
             and S_ORD_ITEM eq SOURCE_FIELDS-S_ORD_ITEM
             and COMP_CODE eq SOURCE_FIELDS-COMP_CODE.
         if sy-subrc eq 0.
              h_flag = 'X'.  " Document found
         endif.
      else.
         h_flag = 'X'.  "Document found.
      endif.
    if h_flag = 'X'.
            if h_dcurr ne SOURCE_FIELDS-CURRENCY.
              if h_rate lt 0.
                h_rate = h_rate * ( -1 ).
                clear h_amount.
                if h_inv ne 0.
                  h_amount = h_inv.
                else.
                  h_amount = SOURCE_FIELDS-/BIC/ZG_AVV104 * h_rate.
                endif.
              elseif h_rate gt 0.
                if h_inv ne 0.
                  h_amount = h_inv.
                else.
                  h_amount = SOURCE_FIELDS-/BIC/ZG_AVV104 / h_rate.
                endif.
              else.
                h_amount = SOURCE_FIELDS-/BIC/ZG_AVV104.
              endif.
            else.
              h_amount = SOURCE_FIELDS-/BIC/ZG_AVV104.
            endif.
            RESULT = h_amount.
            CURRENCY = h_dcurr.
          endif.
        endif.

    Hi,
    what you need to do first is to define internal tables in the start routine for each individual routine with the key fields. So look at the different SELECT SINGLE statements and build up the internal table(s). So for the first one you need to define an internal table with fields BILL_NUM, BILL_ITEM, COMP_CODE  (your key) and EXRATEXACC, DOC_CURRCY and NETVAL_INV. I don't know if you can combine the two select single statements, that will depend on if BILL_NUM is the same type of field as DOC_NUMBER.
    After declaration of the internal tables you can fill the bales by doing a SELECT instead of select single INTO the internal table.
    In the individual update rules you can do a READ TABLE (internal table) WITH KEY yyyyyy
    In this way you only have to access the DB once per data package and read from the internal memory for each record, which will definitely improve performance.
    Hope this helps!

  • Start Routine & DTP

    Hi Friends !
    Facing a bit strange issue. When I run the DTP with selection for all AC_DOC_NO, start routine works fine & I am getting the expected result. But when I run the DTP without selection, result is not as expected. During debugging also I can see the correct records. Please advise.
    With Regards
    Rekha

    Hi,
    If you are loading to DSO, I am sure there could be some overwrite is happening where u r missing the expected records.
    if this is the scenario then try to add keyfield in DSO to overcome from overwrite.

  • Performance with select in Start routine

    Hi,
    I open a request because i have some troubles in a update rules.
    In this update rule i have several select function on master data and i takes just 3-4 minutes by packets (which is OK for my daily extraction). But my users needs now a data taht i need to extract from SD invoice ODS. and in this ODS i have 3 000000 lines.
    I made the test and it takes too many times.
    I try several solutions as :
    Select.... into internal table --> too many times
    Select ... for all entries .... into internal table...--> Too many times
    I tried to create a small ODS with just the key level and data i need for my start routine based on invoice ODS. And i now from 3000000 to 300000 records. but now it takes 15 minutes by packets.
    My question is do you have any idea to improve performance ?
    What is the max size or number of records for an internal tables ?
    Thanks
    Cyril

    Reading that much, you might have some memory issue.
    "Data objects that are defined either with the data type of an internal table, or directly as an internal table, are always fully defined in respect of their line type, key and access method. However, the number of lines is not fixed. Thus internal tables are dynamic data objects, since they can contain any number of lines of a particular type. The only restriction on the number of lines an internal table may contain are the limits of your system installation. The maximum memory that can be occupied by an internal table (including its internal administration) is 2 gigabytes. A more realistic figure is up to 500 megabytes. An additional restriction for hashed tables is that they may not contain more than 2 million entries. The line types of internal tables can be any ABAP data types - elementary, structured, or internal tables. The individual lines of an internal table are called table lines or table entries. Each component of a structured line is called a column in the internal table."
    if you need the link to the above doc....
    http://help.sap.com/saphelp_47x200/helpdata/en/fc/eb3660358411d1829f0000e829fbfe/frameset.htm
    thanks.
    Wond

  • Index used or not for selecting data from ODS in a start routine

    Dear friends,
    In the start routine of the update rules to a cube, I am reading some data of an ODS in to an internal table .
    The ODS is indexed. But, I am not sure if the index is at all used in the Select statement (that gets the data from ODS to the internal table in the start routine) while loading data to the cube.
    Any help is highly appreciated.
    regards,
    atlaj

    Hi Atlaj
    You can findout this is display execution plan for SQL statement in DB02.
    Goto DB02. and under diagnostic, you find explain. Select that and enter your query. Make sure that everything here is in capital format. Below is a sample query which I have entered.
    SELECT "CRM_SALORG" "SALESORG" FROM "/BI0/QORGUNIT"
    WHERE "SALESORG" = ? AND "OBJVERS" = ? AND "DATETO" >= ?
    AND "DATEFROM" <= ?
    The select parameters should be inside qoutes and in caps and even the from table. Once you enter your query in this format, click on explain. It will show the index scan if the index is present. the output for my query will be something like
    0 SELECT STATEMENT ( Estimated Costs =  1,348E+01 [timerons] )
            1 (COOR) RETURN
                2 (    0) TQ
                    3 (    0) FETCH /BI0/QORGUNIT
                        4 (    0) IXSCAN /BI0/QORGUNIT~Z1
    Where my last statement (line 4) is showing index scan and the name of index read is Z1.
    Hope this helps.
    Please let me know if you have any problems entering the query in the specified format and u get any error.
    Regards
    Sriram

  • Strange select statement behavior in start routine during extraction

    Hi, All..
    I'm receiving some odd behavior from a select statment being processed in batch mode (specifically, when run in a normal BW extractor - start routine), the select yields no results .. sy-subrc = 4 and target itab is empty.  however, when i run this same select statement in debug, i get sy-subrc = 0 and records are returned!!  I tried putting the select statement in a standard abap program & it came back successfully in both foreground & background.  something is strange when run in the BW extractor process?? anyone familiar with this?? any help is appreciated!!  Thanks!!

    Thanks everyone for the comments!
    The code is in the start routine from 0BBP_CONF_TD_1 into 0BBP_CON. 
    -The select returns records when in debug
    -I've tried running it open without the "for all entries" & it still fails in batch
    -The select works during the delta but always fails on the initial load
    The select is a join:
    DATA: BEGIN of t_JOIN1 OCCURS 0,
            CONNUM    LIKE /BI0/ABBP_CON00-BBP_CON_ID,
            CONITEM   LIKE /BI0/ABBP_CON00-BBP_COITEM,
            PONUM     LIKE /BI0/ABBP_PO00-BBP_PO_ID,
            POITEM    LIKE /BI0/ABBP_PO00-BBP_POITEM,
            ACGUID    LIKE /BI0/ABBP_PO00-BBP_ACGUID,
            SCNUM     LIKE /BI0/ABBP_SC00-BBP_SC_ID,
            SCITEM    LIKE /BI0/ABBP_SC00-BBP_SCITEM,
            REQSTR    LIKE /BI0/ABBP_SC00-BBP_REQSTR.
    DATA: END of t_JOIN1.
             SELECT a~BBP_CON_ID
                    a~BBP_COITEM
                    a~BBP_PO_ID
                    a~BBP_POITEM
                    b~BBP_ACGUID
                    c~BBP_SC_ID
                    c~BBP_SCITEM
                    c~BBP_REQSTR
               INTO TABLE t_JOIN1
               FROM /BI0/ABBP_CON00 as a
         INNER JOIN /BI0/ABBP_PO00  as b
                 ON aBBP_PO_ID  =  bBBP_PO_ID AND
                    aBBP_POITEM =  bBBP_POITEM
         INNER JOIN /BI0/ABBP_SC00  as c
                 ON bBBP_SC_ID  =  cBBP_SC_ID
                AND bBBP_SCITEM =  cBBP_SCITEM
                FOR ALL ENTRIES IN  DATA_PACKAGE
              WHERE a~BBP_CON_ID =  DATA_PACKAGE-BBP_CON_ID AND
                    a~BBP_COITEM =  DATA_PACKAGE-BBP_COITEM AND
                    a~BBP_COITEM <> 0 AND
                    b~BBP_ACGUID <> '0000' AND
                    c~BBP_SCITEM <> 0.

  • Error "Overlapping selection criteria with DTP" when transporting DTP

    When transporting a DTP from Dev to QA I get the following error in the trasnport log:
    Overlapping selection criteria with DTP DTP_4APJZSGKYQLUQYBCDBWK707JO
    Message no. RSBK019
    Diagnosis
    The selection criteria for the DTP to be activated overlap with the selection criteria of DTP DTP_4APJZSGKYQLUQYBCDBWK707JO in field , for example, with regard to value . Delta transfer from a source object to a target object is only allowed to transfer each record oncce. However, this cannot be guaranteed if two DTPs have overlapping selection criteria with the 'Delta' extraction mode.
    System Response
    You cannot activate the DTP with the current selection criteria.
    Procedure
    Restrict the selection criteria so that they do not overlap with the selection criteria for DTP DTP_4APJZSGKYQLUQYBCDBWK707JO.
    The DTP is a delta process which loads data from one infocube into an DSO. I understand that the error is that it is transporting the Delta parameters (something similar to a Delta initialization of infopackages I suppose) but I don´t how to access the information of the delta (selection criteria) of a DTP.
    Any suggestions? or similar experiences?
    Thanks in advance
    nicolá

    Hello,
    You can modify a parameter to create and modify dtp in Production. Like normally is done with Infopackages. There is no reason to make the changes in Dev in the Infopackages and DTP, and transport to Production. This transports normally cause that kind of errors because the id's are different in Dev, QA and Prod, and it is difficult to change dtp in that way.
    To change the parameter do like this:
    Execute Trx. RSA1 -> Transport Connection -> Tab Object Changeability -> Change DTPA to Everything Changeable.
    Do this in Dev, QA and Prod.
    Regards,
    Jorge Diogo

  • Regarding Selection Criteria features in BI7 Info package maintenance

    Hi,
    In BI7.0, I have to load data from the Business content ODS, 0FIGL_O02 to Customized ODS by restricting the data as per the document types.
    Do we have that feature in BI7, to restrict the data in info package maintenance's selection criteria.Please let me know, when we dont have that feature...where can i apply this restriction for loading one data target to another data target.
    Thanks,

    In BI 7.0 you will be using DTPs to load data from one DSO to the other.  There will be no Infopackages involved.
    You can filter based on Document types in two ways. 
    1.  Build the filter in the start routine of your transformation itself  to delete datapackage whenever document type is not equal to what you want.
    2.  DTPs have a filter button.  When you go in change mode you will be able to choose the infoobjects on which you want to filter.  You can enter the required Document types in the filter here.
    If helpful, assign points

  • Using internal tables in BI 7 Start routines

    Hi All
    I tried searching for using internal tables in a start routine in BI 7 could not find the right pointers.
    This is what I am trying to do is the following:
    In a DSO ZSD_O01  I have a sales order and sales order item number and this DSO also contains the Contract number and the contract Item number.
    The DSO structure is as follows:
    /BIC/AZSD_O0100
    DOC_NUMBER
    ITEM
    CONTRACT
    CITEMNUM
    I want to read the data in this DSO into a internal table. But the key fields in this DSO is DOC_NUMBER and ITEM so I want to read this data into a internal table only for the first data package into the internal table. Thereafter I want to lookup into the internal table given the doc_number and ITEM to find the CONTRACT and CITEMNUM.
    Can any of you kindly show me how to :
    - Read data from a DSO into a internal table
    - Read the internal table for the first data package
    - How do I make the access in the internal table fast when my lookup in the internal table is not on the
      DSO key columns but on a different key column
    Appreciate your help
    Thanks
    Karen

    Hi Karen ,
    It will be helpful if you tell your requirement  as the approach you suggested is not looks convincing .May be their is some easy way and we can suggest you better approach
    -how to check for source_package = 1
    You need to hard code it .
    We decide package size at DTP level so you can declare a global variable .let say you have 50000 size of your  package then use global variable as counter and read only when record_count is <= 50000 .
    -how to declare the internal table so the values in it exists between different data packages
    Declare a global table and select data into it .A global table retain data across  the packages .
    - The key on which I need to lookup in the internal table is not the key fields as in the DSO
    Its ok .Let say you are doing lookup on A B and C field of DSO1 and the values may duplicate  in your source .then you just need to read the internal table having data from DSO2  with key field  A B C .
    Better if you set them as semantic keys at DTP level so that all  duplicate entries of A B  C will appear in same package .
    global Declarations
    In your start routine you will have this following code :
      TYPES:
          tyt_SC_1        TYPE STANDARD TABLE OF tys_SC_1
                            WITH NON-UNIQUE DEFAULT KEY.
    $$ begin of global - insert your declaration only below this line  -
    ...   insert your code here
    $$ end of global - insert your declaration only before this line   -
    One question
    Why you want to populate values for 1 source package only not for all ?This will be helpful to understand your requirement and may be we can fulfill it in some other manner .
    Regards,
    Jaya Tiwari

  • Selection Criteria addition-Not working

    Hi!
    I have this report wherein I need to add two fields VBAP-Kunnr and knvv-konda in the selection screen so that I can do my drill down or search criteria based upon these two selections also apart from the existing ones, but unfortunately I am unable to get throiugh this and somehow putting this two selections in the selection criteria its not taking any effect or its just actinga  dummy selection and I am unale to drill down my report based upon those. Can anyone have a look and let me know what could be the problem please. Help would be highly appreciated.
    Thanks
    *& Include ZSD_PFGENERATETOP Report ZSD_PFGENERATE
    REPORT zsd_pfgenerate LINE-SIZE 170 LINE-COUNT 65.
    TABLES: lips, likp, vbap, vbak, vbrp, vbpa, vbrk.
    CONSTANTS: cns_vgtyp TYPE vbrp-vgtyp VALUE 'J',
    cns_intyp TYPE vbrk-vbtyp VALUE 'M',
    cns_vkorg TYPE vbak-vkorg VALUE 'CA01',
    cns_vkorg_US type vbak-vkorg value 'US01', "DEVK903521
    cns_parsh TYPE vbpa-parvw VALUE 'WE',
    cns_parsp TYPE vbpa-parvw VALUE 'AG',
    cns_parre type vbpa-parvw value 'RE', "bill-to
    cns_auzwp TYPE vbak-auart VALUE 'ZWP',
    cns_auzct TYPE vbak-auart VALUE 'ZCT',
    cns_auzif TYPE vbak-auart VALUE 'ZIF',
    cns_auztm TYPE vbak-auart VALUE 'ZTM',
    cns_fkff TYPE vbrk-fkart VALUE 'ZFF5',
    cns_fkos TYPE vbrk-fkart VALUE 'ZOF5',
    cns_upd(1) TYPE c VALUE 'S',
    cns_mode(1) TYPE c VALUE 'N'.
    Internal Tables and Work Areas
    DATA: BEGIN OF it_vbpos OCCURS 0,
    werks TYPE vbap-werks,
    audat TYPE vbak-audat,
    auart TYPE vbak-auart,
    kunag TYPE vbak-kunnr,
    name1_ag TYPE kna1-name1,
    kunsh TYPE likp-kunnr,
    name1_sh TYPE kna1-name1,
    vbeln TYPE vbak-vbeln,
    posnr TYPE vbap-posnr,
    vbdel TYPE likp-vbeln,
    psdel TYPE lips-posnr,
    kunre type kunre, "Bill-to Party
    name1_re type kna1-name1, "Bill-to Party Name
    END OF it_vbpos,
    BEGIN OF it_vbpos_temp OCCURS 0,
    vgbel TYPE lips-vgbel,
    vgpos TYPE lips-vgpos,
    vbeln TYPE vbak-vbeln,
    posnr TYPE vbap-posnr,
    END OF it_vbpos_temp,
    BEGIN OF it_report OCCURS 0,
    werks TYPE vbap-werks,
    vbeln TYPE vbak-vbeln,
    vbdel TYPE likp-vbeln,
    audat TYPE vbak-audat,
    auart TYPE vbak-auart,
    name1_ag TYPE kna1-name1,
    name1_sh TYPE kna1-name1,
    name1_re type kna1-name1, "Bill-to Party Name
    mark(1) TYPE c,
    END OF it_report,
    BEGIN OF it_vbeln OCCURS 0,
    vbeln TYPE vbak-vbeln,
    END OF it_vbeln,
    wa_vbeln LIKE LINE OF it_vbeln,
    wa_vbpos LIKE LINE OF it_vbpos,
    wa_report LIKE LINE OF it_report,
    wa_sel LIKE LINE OF it_report.
    DATA: it_vbrp type table of vbrp,
    it_vbrk type table of vbrk.
    BDC Variables
    DATA: BEGIN OF bdc_tab OCCURS 0.
    INCLUDE STRUCTURE bdcdata.
    DATA: END OF bdc_tab.
    DATA: wa_bdc LIKE LINE OF bdc_tab,
    it_bdcmess TYPE TABLE OF bdcmsgcoll.
    *& Selection-Screen definition
    SELECTION-SCREEN BEGIN OF BLOCK block2 WITH FRAME TITLE text-002.
    PARAMETERS: p_rdff TYPE c RADIOBUTTON GROUP rad1 DEFAULT 'X',
    p_rdos TYPE c RADIOBUTTON GROUP rad1.
    SELECTION-SCREEN END OF BLOCK block2.
    SELECTION-SCREEN BEGIN OF BLOCK block0 WITH FRAME TITLE text-000.
    SELECT-OPTIONS: s_werks FOR vbap-werks OBLIGATORY NO INTERVALS,
    s_auart FOR vbak-auart,
    s_kunag FOR vbak-kunnr, "Sold-to Party
    s_kunnr FOR likp-kunnr, "Ship-to Party
    s_kunre for vbak-kunnr, "Bill to Party
    s_vdatu FOR vbak-vdatu OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK block0.
    SELECTION-SCREEN BEGIN OF BLOCK block1 WITH FRAME TITLE text-001.
    PARAMETERS: p_vgbel TYPE vbak-vgbel.
    SELECTION-SCREEN END OF BLOCK block1.
    selection-screen begin of block block3 with frame title text-003.
    parameters: p_billed RADIOBUTTON GROUP r1,
    p_delvd RADIOBUTTON GROUP r1 default 'X',
    p_all RADIOBUTTON GROUP r1.
    selection-screen end of block block3.
    *& Include ZSD_PFGENERATEE01
    START-OF-SELECTION.
    PERFORM read_report.
    END-OF-SELECTION.
    SET PF-STATUS 'STAT1000'.
    IF it_vbpos[] IS INITIAL.
    MESSAGE s999(z001) WITH 'No Data Selected for this criteria'.
    ELSE.
    PERFORM show_report.
    ENDIF.
    *& List Events
    AT USER-COMMAND.
    CASE sy-ucomm.
    WHEN 'SELE'.
    LOOP AT it_report INTO wa_report.
    wa_report-mark = 'X'.
    MODIFY it_report FROM wa_report.
    ENDLOOP.
    PERFORM show_report.
    WHEN 'DSEL'.
    LOOP AT it_report INTO wa_report.
    wa_report-mark = ''.
    MODIFY it_report FROM wa_report.
    ENDLOOP.
    PERFORM show_report.
    ENDCASE.
    AT LINE-SELECTION.
    DO.
    READ LINE sy-index FIELD VALUE wa_report-mark wa_report-vbeln
    wa_report-vbdel.
    IF sy-subrc NE 0.
    EXIT.
    ELSE.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    input = wa_report-vbeln
    IMPORTING
    output = wa_report-vbeln.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    input = wa_report-vbdel
    IMPORTING
    output = wa_report-vbdel.
    READ TABLE it_report INTO wa_sel
    WITH KEY vbeln = wa_report-vbeln.
    IF sy-subrc EQ 0.
    wa_sel-mark = wa_report-mark.
    MODIFY it_report FROM wa_sel INDEX sy-tabix.
    ENDIF.
    ENDIF.
    ENDDO.
    REFRESH: it_vbeln.
    LOOP AT it_report INTO wa_report WHERE mark EQ 'X'.
    CASE 'X'.
    WHEN p_rdff.
    wa_vbeln = wa_report-vbdel.
    WHEN p_rdos.
    wa_vbeln = wa_report-vbeln.
    ENDCASE.
    APPEND wa_vbeln TO it_vbeln.
    ENDLOOP.
    SORT it_vbeln BY vbeln.
    DELETE ADJACENT DUPLICATES FROM it_vbeln.
    IF NOT it_vbeln[] IS INITIAL.
    PERFORM process_vf01.
    ENDIF.
    *& Include ZSD_PFGENERATEF01
    *& Form read_report
    Routine to read applicable orders from database
    FORM read_report.
    DATA: lwa_lips TYPE lips,
    lc_vbeln TYPE vbrk-vbeln.
    Retrieve sales orders based on selection criteria where billing doc has not been
    created for the delivery yet
    REFRESH: it_vbeln, it_vbpos, it_report.
    Select into table based on Onsite/Fixed Facility
    CASE 'X'.
    WHEN p_rdff.
    changed for performance reasons (i.e. time-out)
    k~vgbel is not in it_vbpos but was in select statment ?
    SELECT vbap~werks vbak~audat vbak~auart vbak~kunnr AS kunag
    vbak~vbeln vbap~posnr
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos
    FROM vbak INNER JOIN vbap
    ON vbak~mandt = vbap~mandt
    AND vbak~vbeln = vbap~vbeln
    WHERE vbap~werks IN s_werks
    AND vbak~vdatu IN s_vdatu
    AND vbak~vkorg in (cns_vkorg,cns_vkorg_US)
    AND vbap~oid_ship IN s_kunnr
    AND vbak~kunnr IN s_kunag
    AND vbak~auart IN s_auart
    AND ( vbak~auart = 'ZWP' or vbak~auart = 'ZIF' or
    vbak~auart = 'ZCT' or vbak~auart = 'ZTM' or
    vbak~auart = 'ZOIL' ).
    IF SY-SUBRC = 0.
    SELECT vgbel vgpos vbeln posnr FROM lips
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos_temp
    FOR ALL ENTRIES IN it_vbpos
    WHERE vgbel = it_vbpos-vbeln
    AND vgpos = it_vbpos-posnr
    %_hints oracle 'index ("LIPS" "LIPS~Z01")'.
    SORT it_vbpos_temp by vgbel vgpos.
    LOOP AT it_vbpos.
    READ TABLE it_vbpos_temp
    WITH KEY vgbel = it_vbpos-vbeln vgpos = it_vbpos-posnr
    BINARY SEARCH.
    IF SY-SUBRC = 0.
    it_vbpos-vbdel = it_vbpos_temp-vbeln.
    it_vbpos-psdel = it_vbpos_temp-posnr.
    modify it_vbpos.
    ENDIF.
    ENDLOOP.
    ENDIF.
    WHEN p_rdos.
    SELECT k~vbeln p~posnr k~kunnr AS kunag k~audat k~auart p~werks k~vgbel
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos
    FROM vbak AS k INNER JOIN vbap AS p ON k~vbeln = p~vbeln
    WHERE p~werks IN s_werks AND k~vdatu IN s_vdatu AND
    k~vkorg in (cns_vkorg,cns_vkorg_US) AND "DEVK903521
    k~vgbel EQ p_vgbel AND
    k~kunnr IN s_kunag AND k~auart IN s_auart AND
    p~oid_ship IN s_kunnr.
    ENDCASE.
    Determine if delivery has been billed out, if not can create PF Invoice - CHANGED
    LOOP AT it_vbpos INTO wa_vbpos.
    Check Ship-to in
    SELECT SINGLE kunnr INTO wa_vbpos-kunsh FROM vbpa
    WHERE parvw EQ cns_parsh AND vbeln EQ wa_vbpos-vbeln.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    Check for Bill-to
    select single kunnr into wa_vbpos-kunre from vbpa
    where parvw eq cns_parre and vbeln eq wa_vbpos-vbeln
    and kunnr in s_kunre.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    Get Partner Texts
    SELECT SINGLE name1 INTO wa_vbpos-name1_ag FROM kna1
    WHERE kunnr EQ wa_vbpos-kunag.
    SELECT SINGLE name1 INTO wa_vbpos-name1_sh FROM kna1
    WHERE kunnr EQ wa_vbpos-kunsh.
    SELECT SINGLE name1 INTO wa_vbpos-name1_re FROM kna1
    WHERE kunnr EQ wa_vbpos-kunre.
    CASE 'X'.
    WHEN p_rdff.
    IF p_delvd = 'X'.
    optimized for performance reasons i.e. time-out
    Check if delivery has been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON p~vbeln = k~vbeln
    WHERE p~vgtyp EQ cns_vgtyp AND p~vgbel EQ wa_vbpos-vbdel AND
    p~vgpos EQ wa_vbpos-psdel AND k~vbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc EQ 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ELSEIF p_billed = 'X'.
    Check if delivery hasn't been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON p~vbeln = k~vbeln
    WHERE p~vgtyp EQ cns_vgtyp AND p~vgbel EQ wa_vbpos-vbdel AND
    p~vgpos EQ wa_vbpos-psdel AND k~vbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ENDIF.
    WHEN p_rdos.
    IF p_delvd = 'X'.
    Check if order has been billed out
    SELECT SINGLE * FROM vbrp
    WHERE vbeln EQ wa_vbpos-vbeln AND
    vgpos EQ wa_vbpos-posnr.
    IF sy-subrc EQ 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    ELSEIF p_billed = 'X'.
    Check if delivery hasn't been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON pvbeln = kvbeln
    WHERE pvgtyp EQ cns_vgtyp AND pvgbel EQ wa_vbpos-vbdel AND
    pvgpos EQ wa_vbpos-psdel AND kvbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ENDIF.
    ENDCASE.
    MOVE-CORRESPONDING wa_vbpos TO wa_report.
    APPEND wa_report TO it_report.
    MODIFY it_vbpos FROM wa_vbpos.
    ENDLOOP.
    if 'onsite field summary', then process by release sales orders
    IF p_rdos = 'X'.
    sort it_report by vbeln.
    delete adjacent duplicates from it_report comparing vbeln.
    else.
    SORT it_report BY werks name1_ag name1_sh vbeln.
    DELETE ADJACENT DUPLICATES FROM it_report.
    endif.
    SORT it_report BY name1_sh werks name1_ag vbeln.
    ENDFORM. " read_report
    *& Form process_vf01
    Call transaction VF01 and fill screen table with order values
    FORM process_vf01.
    DATA: ln_index(2) TYPE n,
    lc_field(20) TYPE c,
    lc_fkart TYPE vbrk-fkart,
    li_lines TYPE i,
    lc_msgtxt(99) TYPE c,
    lwa_bdcoptions TYPE ctu_params,
    lwa_mess LIKE LINE OF it_bdcmess.
    REFRESH: it_bdcmess.
    lwa_bdcoptions-dismode = cns_mode.
    lwa_bdcoptions-updmode = cns_upd.
    CASE 'X'.
    WHEN p_rdff.
    lc_fkart = cns_fkff.
    WHEN p_rdos.
    lc_fkart = cns_fkos.
    ENDCASE.
    REFRESH: bdc_tab.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0102',
    ' ' 'BDC_CURSOR' 'RV60A-FKART',
    ' ' 'RV60A-FKART' lc_fkart,
    ' ' 'BDC_OKCODE' '/00'.
    LOOP AT it_vbeln INTO wa_vbeln.
    ln_index = sy-tabix.
    Up to the second delivery of the BDC add the Delivery to the screen, after that click the More Documents for every entry. logic changed for DEVK902353
    CASE ln_index.
    WHEN 1.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln.
    WHEN 2 OR 3.
    IF p_rdos 'X'.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln,
    'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' 'FKAN'..
    ELSE.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln.
    ENDIF.
    WHEN OTHERS.
    If p_rdos 'X'.
    CONCATENATE 'KOMFK-VBELN' '(2)' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln,
    'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' 'FKAN'.
    endif.
    ENDCASE.
    ENDLOOP.
    VF01 will go to a different screen if only one line selected
    DESCRIBE TABLE it_vbeln LINES li_lines.
    IF li_lines EQ 1.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0104',
    ' ' 'BDC_OKCODE' '=SICH'.
    ELSE.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' '=SICH'.
    ENDIF.
    CALL TRANSACTION 'VF01' USING bdc_tab OPTIONS FROM lwa_bdcoptions
    MESSAGES INTO it_bdcmess.
    WRITE: / 'BDC Messages:'.
    SKIP.
    LOOP AT it_bdcmess INTO lwa_mess.
    CALL FUNCTION 'RH_MESSAGE_GET'
    EXPORTING
    arbgb = 'VF'
    msgnr = lwa_mess-msgnr
    msgv1 = lwa_mess-msgv1
    msgv2 = lwa_mess-msgv2
    msgv3 = lwa_mess-msgv3
    msgv4 = lwa_mess-msgv4
    IMPORTING
    msgtext = lc_msgtxt
    EXCEPTIONS
    message_not_found = 1
    OTHERS = 2.
    WRITE: /5 lc_msgtxt.
    ENDLOOP.
    ENDFORM. " process_vf01
    form update_bdc *
    subroutine to add the data to the bdc table for trans. vf01 *
    FORM update_bdc USING dynpro field content.
    CLEAR bdc_tab.
    IF dynpro EQ 'X'.
    bdc_tab-program = field.
    bdc_tab-dynpro = content.
    bdc_tab-dynbegin = 'X'.
    ELSE.
    bdc_tab-fnam = field.
    bdc_tab-fval = content.
    ENDIF.
    APPEND bdc_tab.
    ENDFORM. "UPDATE_BDC
    *& Form show_report
    Report to Display Available Orders on Screen
    FORM show_report .
    DATA: l_idx TYPE i.
    WRITE: / 'Available Orders/Deliveries for Plant:'.
    LOOP AT s_werks.
    WRITE: s_werks-low.
    ENDLOOP.
    SKIP.
    FORMAT INTENSIFIED ON COLOR COL_HEADING.
    WRITE: /5 text-h01, text-h02.
    CASE 'X'.
    WHEN p_rdff.
    WRITE: text-h06.
    ENDCASE.
    WRITE: text-h03, text-h04, text-h05, text-h07,
    / sy-uline.
    FORMAT INTENSIFIED OFF COLOR OFF.
    l_idx = 0.
    LOOP AT it_report INTO wa_report.
    IF l_idx EQ 0.
    FORMAT COLOR COL_NORMAL INTENSIFIED ON.
    l_idx = 1.
    ELSE.
    FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
    l_idx = 0.
    ENDIF.
    WRITE: / wa_report-mark AS CHECKBOX,
    wa_report-auart UNDER text-h01,
    wa_report-vbeln UNDER text-h02.
    CASE 'X'.
    WHEN p_rdff.
    WRITE: wa_report-vbdel UNDER text-h06.
    ENDCASE.
    WRITE: wa_report-audat UNDER text-h03,
    wa_report-name1_ag UNDER text-h04,
    wa_report-name1_sh UNDER text-h05,
    wa_report-name1_re under text-h07.
    HIDE: wa_report-mark, wa_report-vbeln, wa_report-vbdel.
    ENDLOOP.
    ENDFORM. " show_report
    Thanks for your kind help.
    Aarav.

    Hi, Anne-Marie;
    You may be running into a common issue that is docuemented here:
    [SelectionFormula|https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_erq/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes%7B6163636573733d36393736354636443646363436353344333933393338323636393736354637333631373036453646373436353733354636453735364436323635373233443330333033303331333233303334333833393335%7D.do]
    Regards,
    Jonathan
    Edited by: Jonathan Parminter on Mar 16, 2009 8:03 AM

  • DTP Selection condition

    Hi Experts,
    I wanted to know if we can read selection conditions maintained in DTP in the start routine using any custom code or using any standard function module.
    Any help will be appreciated.
    Thanks,

    Hi,
    You can do that by writing code to select data from this table RSBKDATAPAKSEL
    Hope this helps
    TRUC

  • How to set request number of info package using start routine

    Hi All,
    I have a specific requirement in which I need to upload only selective request nos from PSA to DSO.
    Any one can suggest how to set request number of info package using start routine or any other mode so that only selective request should proceed using DTP?
    Thanks
    Sangita

    You'll probably want to do this in a start routine.  It is probably not advisable to hard-code the technical name of the InfoPak.  They seem to remain the same upon transport, unlike DTP technical names which are locally generated.
    I would do a SQL select like this in a start routine, and then filter based on the results of the SQL.  You'll probably want to sort the results by date and time, both descending.  Or do a MAX in the SQL.
    Please let me know if this isn't clear.
    select q~rnr q~logdpid q~tdatum q~tuzeit
    from rsreqdone as q
      inner join rsldpio as p
        on p~logdpid = q~logdpid
    where p~objvers = 'A'
    and p~logdpid like 'ZPAK%'
    and p~source = 'your data source'

  • Restricting data in cube using start routine

    Hi,
    Can anyone help me with my scenariou2026.I am trying to restrict the absence data being loaded into the cube where the absence is less than or equal to twenty.
    Firstly I put in a start routine in the update rules against actual time.
    DELETER DATA_PACKAGE WHERE  DUR_ACTUAL GT 20
    But this didnu2019t work.
    Secondly I put this code in the change routine for the key figure actual time
    IF RESULT GT 20.
      RETURNCODE = 1.
    ELSE.
      RETURNCODE = 0.
    ENDIF.
    But all the actual time fields were set to 0.
    Can anyone please help with the correct code.
    Thanks
    Forhad

    It is hard to say without debugging your code, and inspecting the input package.  Maybe you just need quotes around your values, or something simple like that.
    But did you know that it is faster to put a filter in a DTP?  Using a filter, you're pushing the criteria down to the SQL WHERE clause, and limiting the amount of data.
    And, you're eliminating the need for ABAP.
    Sorry, if you're not on BI7, disregard, because you don't have DTPs.
    Edited by: Jerry Coleman on Jan 29, 2009 10:05 AM

Maybe you are looking for