Filling range using..... bdcdata

Hi ,
I have a requuirement that , need to call a standard report in a new session when i click on first level output.Am using ' FM ABAP4_CALL_TRANSACTION' STARTING NEW TASK to create anew session by  filling bdcdata
but problem is...i wanted to submit a range to report.
Can any one let me know how to submit a range using BDCDATA...
Thanks in advance..
Regards,
Anand Lokineni.

Hi,
I believe by ranges you mean data to select options of a selection screen ?
If yes, I just recorded one standard transaction tx.MB5S and created a function module for the recording.
Here is the snippet of the function module:
FUNCTION Z_MB5S_CALL.
" this is the part which populated the select option of the selection screen.
perform bdc_dynpro      using 'SAPLALDB' '3000'.
perform bdc_field       using 'BDC_OKCODE'
                              '=ACPT'.
" The value is passed by first setting the cursor on the field and then setting the value.
"1. Set the cursor.
perform bdc_field       using 'BDC_CURSOR'
                              'RSCSEL-SLOW_I(01)'.
"2. Set the value
perform bdc_field       using 'RSCSEL-SLOW_I(01)' 
                              SLOW_I_01_002.
" Same for the others.
perform bdc_field       using 'RSCSEL-SLOW_I(02)'
                              SLOW_I_02_003.
perform bdc_field       using 'RSCSEL-SLOW_I(03)'
                              SLOW_I_03_004.
perform bdc_field       using 'RSCSEL-SLOW_I(04)'
                              SLOW_I_04_005.
perform bdc_field       using 'RSCSEL-SLOW_I(05)'
                              SLOW_I_05_006.
perform bdc_field       using 'RSCSEL-SLOW_I(06)'
                              SLOW_I_06_007.
perform bdc_field       using 'RSCSEL-SLOW_I(07)'
                              SLOW_I_07_008.
perform bdc_field       using 'RSCSEL-SLOW_I(08)'
                              SLOW_I_08_009.
perform bdc_field       using 'RSCSEL-SLOW_I(09)'
                              SLOW_I_09_010.
perform bdc_dynpro      using 'RM07MSAL' '1000'.
perform bdc_field       using 'BDC_CURSOR'
                              'LIFNR-LOW'.
perform bdc_field       using 'BDC_OKCODE'
                              '=ONLI'.
perform bdc_field       using 'EKORG-LOW'
                              LOW_011.
perform bdc_field       using 'FINAL'
                              FINAL_012.
perform bdc_dynpro      using 'SAPMSSY0' '0120'.
perform bdc_field       using 'BDC_OKCODE'
                              '=&F03'.
perform bdc_dynpro      using 'RM07MSAL' '1000'.
perform bdc_field       using 'BDC_OKCODE'
                              '/EE'.
perform bdc_field       using 'BDC_CURSOR'
                              'LIFNR-LOW'.
perform bdc_transaction tables messtab
using                         'MB5S'
                              CTU
                              MODE
                              UPDATE.
if sy-subrc <> 0.
  subrc = sy-subrc.
  exit.
endif.
perform close_group using     CTU.
ENDFUNCTION.
This is a custom function module, so you can tweak this function's tables parameter to receive the list of values for the range and loop at this list and populate the range/select options as shown above.
Hope this solves the issue.
regards,
Advait

Similar Messages

  • How to populate the ranges using FM for the SELECTs

    Hi,
    I am still working on the FM to create a generic extractor. I went through the debugger but I am still unable to determine how the ranges are populated. RSA3 always gives me zero values for the results.
    There is a RANGE statement in the sample FM and the following statements for SELECTs
      RANGES: L_R_CARRID  FOR SFLIGHT-CARRID,
              L_R_CONNID  FOR SFLIGHT-CONNID.
    and...
          LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'CARRID'.
            MOVE-CORRESPONDING L_S_SELECT TO L_R_CARRID.
            APPEND L_R_CARRID.
          ENDLOOP.
          LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'CONNID'.
            MOVE-CORRESPONDING L_S_SELECT TO L_R_CONNID.
            APPEND L_R_CONNID.
          ENDLOOP.
    My question is how is L_R_CONNID and L_R_CARRID populated with low and high values for the SELECT statements? I tried to find the DS 0SAPI_SFLIGHT_SIMPLE to run and see how it is set up but there is no such DS.
    Would someone take the time to say something about this in  several sentences? I have my own code and it seems that it is not populating the values for the SELECTs when I debug from RSA3 when I provide the low and high values.
    Would I normally populate the low and high values from the InfoPackage 'Data Selection' tab once I have implemented in BW or ready to test in BW? That would mean I have to choose those fields as selections from RSO2. Anyway, I think I have asked about this but I am hoping to get an answer to get this going...
    Appreciate any replies.

    Hi
    Here is an example of an extractor that uses
    both method's, if the InfoPackage selection exist's
    it overrides the TVARV selection (which is the default).
    FUNCTION ZBW_TC_FORECAST_SO_EXTRACTOR.
    ""Local interface:
    *"  IMPORTING
    *"     VALUE(I_REQUNR) TYPE  SBIWA_S_INTERFACE-REQUNR
    *"     VALUE(I_DSOURCE) TYPE  SBIWA_S_INTERFACE-ISOURCE OPTIONAL
    *"     VALUE(I_CHABASNM) TYPE  SBIWA_S_INTERFACE-CHABASNM OPTIONAL
    *"     VALUE(I_MAXSIZE) TYPE  SBIWA_S_INTERFACE-MAXSIZE OPTIONAL
    *"     VALUE(I_INITFLAG) TYPE  SBIWA_S_INTERFACE-INITFLAG OPTIONAL
    *"     VALUE(I_UPDMODE) TYPE  SBIWA_S_INTERFACE-UPDMODE OPTIONAL
    *"     VALUE(I_DATAPAKID) TYPE  SBIWA_S_INTERFACE-DATAPAKID OPTIONAL
    *"     VALUE(I_PRIVATE_MODE) OPTIONAL
    *"     VALUE(I_CALLMODE) TYPE  ROARCHD200-CALLMODE OPTIONAL
    *"  TABLES
    *"      I_T_SELECT TYPE  SBIWA_T_SELECT OPTIONAL
    *"      I_T_FIELDS TYPE  SBIWA_T_FIELDS OPTIONAL
    *"      E_T_DATA STRUCTURE  ZBW_TC_FORECASTING_EXT_STR OPTIONAL
    *"  EXCEPTIONS
    *"      NO_MORE_DATA
    *"      ERROR_PASSED_TO_MESS_HANDLER
    *"      HIERARCHY_NOT_FOUND
    Change History                                                      *
    Mod. #  |  Date    |  Developer     |  Description                  *
    *RD3K915762|06/21/2005| SRangaraj      | Change selection of open SO   *
             |          |                | data to include deleted matls *
             |          |                | and obsolete items too        *
    RD3K915888|06/29/2005| SRANGARAJ      | Add ext matl grp and lab offce
             |          |                | filters for data-selection    *
    The input parameter I_DATAPAKID is not supported yet !
    Auxiliary Selection criteria structure
      DATA: L_S_SELECT TYPE SBIWA_S_SELECT.
    Maximum number of lines for DB table
      STATICS L_MAXSIZE TYPE SBIWA_S_INTERFACE-MAXSIZE.
    Parameter I_PRIVATE_MODE:
    Some applications might want to use this function module for other
    purposes as well (e.g. data supply for OLTP reporting tools). If the
    processing logic has to be different in this case, use the optional
    parameter I_PRIVATE_MODE (not supplied by BIW !) to distinguish
    between BIW calls (I_PRIVATE_MODE = SPACE) and other calls
    (I_PRIVATE_MODE = X).
    If the message handling has to be different as well, define Your own
    messaging macro which interprets parameter I_PRIVATE_MODE. When
    called by BIW, it should use the LOG_WRITE macro, otherwise do what
    You want.
    Initialization mode (first call by SAPI) or data transfer mode
    (following calls) ?
      IF I_INITFLAG = SBIWA_C_FLAG_ON.
    Initialization: check input parameters
                    buffer input parameters
                    prepare data selection
    The input parameter I_DATAPAKID is not supported yet !
    Invalid second initialization call -> error exit
        IF NOT G_FLAG_INTERFACE_INITIALIZED IS INITIAL.
          IF 1 = 2. MESSAGE E008(R3). ENDIF.
          LOG_WRITE 'E'                    "message type
                    'R3'                   "message class
                    '008'                  "message number
                    ' '                    "message variable 1
                    ' '.                   "message variable 2
          RAISE ERROR_PASSED_TO_MESS_HANDLER.
        ENDIF.
    Check InfoSource validity
        CASE I_DSOURCE.
          WHEN 'ZBW_TC_SO_EXTRACT'.
          WHEN OTHERS.
            IF 1 = 2. MESSAGE E009(R3). ENDIF.
            LOG_WRITE 'E'                  "message type
                      'R3'                 "message class
                      '009'                "message number
                      I_DSOURCE            "message variable 1
                      ' '.                 "message variable 2
            RAISE ERROR_PASSED_TO_MESS_HANDLER.
        ENDCASE.
    Check for supported update mode
       CASE I_UPDMODE.
         WHEN 'F'.
         WHEN OTHERS.
           IF 1 = 2. MESSAGE E011(R3). ENDIF.
           LOG_WRITE 'E'                  "message type
                     'R3'                 "message class
                     '011'                "message number
                     I_UPDMODE            "message variable 1
                     ' '.                 "message variable 2
           RAISE ERROR_PASSED_TO_MESS_HANDLER.
       ENDCASE.
    Check for obligatory selection criteria
       READ TABLE I_T_SELECT INTO L_S_SELECT WITH KEY FIELDNM = 'PGMID'.
       IF SY-SUBRC <> 0.
         IF 1 = 2. MESSAGE E010(R3). ENDIF.
         LOG_WRITE 'E'                    "message type
                   'R3'                   "message class
                   '010'                  "message number
                   'PGMID'                "message variable 1
                   ' '.                   "message variable 2
         RAISE ERROR_PASSED_TO_MESS_HANDLER.
       ENDIF.
        APPEND LINES OF I_T_SELECT TO G_T_SELECT.
    Fill parameter buffer for data extraction calls
        G_S_INTERFACE-REQUNR    = I_REQUNR.
        G_S_INTERFACE-ISOURCE   = I_DSOURCE.
        G_S_INTERFACE-MAXSIZE   = I_MAXSIZE.
        G_S_INTERFACE-INITFLAG  = I_INITFLAG.
        G_S_INTERFACE-UPDMODE   = I_UPDMODE.
        G_S_INTERFACE-DATAPAKID = I_DATAPAKID.
        G_FLAG_INTERFACE_INITIALIZED = SBIWA_C_FLAG_ON.
    Fill field list table for an optimized select statement
    (in case that there is no 1:1 relation between InfoSource fields
    and database table fields this may be far from beeing trivial)
        APPEND LINES OF I_T_FIELDS TO G_T_FIELDS.
    Fill range tables for fixed InfoSources. In the case of generated
    InfoSources, the usage of a dynamical SELECT statement might be
    more reasonable. BIW will only pass down simple selection criteria
    of the type SIGN = 'I' and OPTION = 'EQ' or OPTION = 'BT'.
        LOOP AT G_T_SELECT INTO L_S_SELECT.
          CASE L_S_SELECT-FIELDNM.
            WHEN 'PRDHA'.
              WGF_PRDHA_LENGTH = STRLEN( L_S_SELECT-LOW ).
              IF WGF_PRDHA_LENGTH = 6.  "PARTIAL PRDHA
                 WGF_PRDHA = L_S_SELECT-LOW.
                 CONCATENATE WGF_PRDHA '%' INTO WGF_PRDHA.
              ELSEIF WGF_PRDHA_LENGTH = 12.  "FULL PRDHA
              MOVE-CORRESPONDING L_S_SELECT TO L_R_PRDHA.
              APPEND L_R_PRDHA.
              ENDIF.
            WHEN 'MATKL'.
              MOVE-CORRESPONDING L_S_SELECT TO L_R_MATKL.
              APPEND L_R_MATKL.
          ENDCASE.
        ENDLOOP.
    reset the index of where we are in the gt_header table
      g_tabix = 0.
      perform populate_default_variables.
      perform get_data.
      perform build_detail.
        EXIT.
      ENDIF.                 "Initialization mode or data extraction ?
    Data transfer: First Call      OPEN CURSOR + FETCH
                   Following Calls FETCH only
    First data package -> OPEN CURSOR
       IF G_COUNTER_DATAPAKID = 0.
    Determine number of database records to be read per FETCH statement
    from input parameter I_MAXSIZE. If there is a one to one relation
    between InfoSource table lines and database entries, this is trivial.
    In other cases, it may be impossible and some estimated value has to
    be determined.
      DESCRIBE TABLE LT_DATA LINES l_count.
      IF g_tabix GE l_count.
        RAISE no_more_data.
      ENDIF.
    *CLEAN UP THE OUTPUT TABLE
      refresh E_T_DATA.
      LOOP AT LT_DATA FROM G_TABIX INTO LS_DATA.
        APPEND LS_DATA TO E_T_DATA.
    Set global counter
        g_tabix = g_tabix + 1.
      ENDLOOP.
       G_COUNTER_DATAPAKID = G_COUNTER_DATAPAKID + 1.
    ENDIF.              "Initialization mode or data extraction ?
    ENDFUNCTION.
    Forms
    ***INCLUDE LZBW_TC_FORECAST_SO_EXTF01 .
    *&      Form  populate_default_variables
          text
    -->  p1        text
    <--  p2        text
    FORM populate_default_variables.
      data: wlf_name like tvarv-name.
      clear: R_prdh3[], wlf_name.
    *get the exclusion range from tvarv for the product hierarchy in
    *question
      concatenate 'ZBW_EXL_' WGF_PRDHA(6) INTO WLF_NAME.
    SELECT LOW FROM TVARV INTO R_prdh3-low WHERE
                                 NAME = WLF_NAME.
      move:  'I'    to R_prdh3-sign,
             'EQ'   to R_prdh3-option.
      append R_prdh3.
      clear R_prdh3.
    ENDSELECT.
    {Start of insert by SRangaraj on June 29, 2005 >>RD3K915888
    CLEAR L_R_LABOR[].
    SELECT LOW FROM TVARV INTO L_R_LABOR-Low WHERE
                                 NAME = 'ZBW_TC_FORECAST_LAB_OFF'.
      move:  'I'    to L_R_LABOR-sign,
             'EQ'   to L_R_LABOR-option.
      append L_R_LABOR.
      clear L_R_LABOR.
    ENDSELECT.
    }End of insert by SRangaraj on June 29, 2005 >>RD3K915888
    ENDFORM.                    " populate_default_variables
    *&      Form  get_data
          text
    -->  p1        text
    <--  p2        text
    FORM get_data.
      data: wlf_lmeng like vbep-lmeng.
    *get all deliveries for date range for either a range of product hrchy
    *or a like value
      refresh int_records1.
      if wgf_prdha ne space.
        select ivbeln iposnr iKLMENG jvkorg i~werks
               imatnr imeins mprdha mmatkl
        from vbap as i
           INNER JOIN VBAK AS j
           ON ( jvbeln = ivbeln
                and j~vbtyp = 'C' )
           INNER JOIN vbuk AS k
           ON ( kvbeln = ivbeln
                and k~lfgsk <> 'C'
                and k~gbstk <> 'C' )
           INNER JOIN vbup AS l
           ON ( lvbeln = ivbeln and
                lposnr = iposnr
                and l~lfgsa <> 'C'
                and l~gbsta <> 'C' )
           INNER JOIN mara AS m
           ON ( mmatnr = imatnr
    {Start of insert by SRangaraj on June 21, 2005 >>RD3K915762
                and m~lvorm eq ' '
                and m~mstae ne '99'
    {Start of insert by SRangaraj on June 29, 2005 >>RD3K915888
                and m~extwg = '080' )
    }End of insert by SRangaraj on June 29, 2005 >>RD3K915888
           INNER JOIN marc AS n
           ON ( nmatnr = imatnr
                and nwerks = iwerks
                and n~lvorm eq ' ' )
    }End of insert by SRangaraj on June 21, 2005 >>RD3K915762
        into table int_records1 where ( i~abgru = '  '
                                     and i~klmeng > 0
                                     and m~prdha like wgf_prdha
                                     and m~matkl in l_r_matkl
    {Start of insert by SRangaraj on June 29, 2005 >>RD3K915888
                                     and m~labor in l_r_labor ).
    }End of insert by SRangaraj on June 29, 2005 >>RD3K915888
      elseif not l_r_prdha[] is initial and wgf_prdha = space.
        select ivbeln iposnr iKLMENG jvkorg i~werks
               imatnr imeins mprdha mmatkl
        from vbap as i
           INNER JOIN VBAK AS j
           ON ( jvbeln = ivbeln
                and j~vbtyp = 'C' )
           INNER JOIN vbuk AS k
           ON ( kvbeln = ivbeln
                and k~lfgsk <> 'C'
                and k~gbstk <> 'C' )
           INNER JOIN vbup AS l
           ON ( lvbeln = ivbeln and
                lposnr = iposnr
                and l~lfgsa <> 'C'
                and l~gbsta <> 'C' )
           INNER JOIN mara AS m
           ON ( mmatnr = imatnr
    {Start of insert by SRangaraj on June 21, 2005 >>RD3K915762
                and m~lvorm eq ' '
                and m~mstae ne '99'
    {Start of insert by SRangaraj on June 29, 2005 >>RD3K915888
                and m~extwg = '080' )
    }End of insert by SRangaraj on June 29, 2005 >>RD3K915888
           INNER JOIN marc AS n
           ON ( nmatnr = imatnr
                and nwerks = iwerks
                and n~lvorm eq ' ' )
    }End of insert by SRangaraj on June 21, 2005 >>RD3K915762
        into table int_records1 where ( i~abgru = '  '
                                     and i~klmeng > 0
                                     and m~prdha in l_r_prdha
                                     and m~matkl in l_r_matkl
    {Start of insert by SRangaraj on June 29, 2005 >>RD3K915888
                                     and m~labor in l_r_labor ).
    }End of insert by SRangaraj on June 29, 2005 >>RD3K915888
    endif.
        sort int_records1 by vbeln posnr.
        delete adjacent duplicates from int_records1 comparing
        vbeln posnr.
    *remove unnecessary records
        if not r_prdh3[] is initial.
        DELETE INT_RECORDS1 WHERE PRDHA+6(3) IN r_prdh3.
        endif.
    *get the schedule lines for all of the above records and
    *get the lowest schedule line date per so line item
         if not int_records1[] is initial.
         refresh int_records3.
         select vbeln posnr etenr mbdat into table int_records3
         from vbep for all entries in int_records1
                           where vbeln = int_records1-vbeln and
                                 posnr = int_records1-posnr and
                                 lmeng > 0.
         sort int_records3 by vbeln posnr etenr mbdat ascending.
         loop at int_Records1.
           loop at int_records3 where vbeln = int_records1-vbeln
                                  and posnr = int_records1-posnr.
             int_records1-mbdat = int_records3-mbdat.
             modify int_records1.
             exit.
            endloop.
         endloop.
         refresh int_records3. free int_records3.
         refresh int_records2.
    *get the deliveries and calculate the open quantities
        select vbelv posnv vbeln posnn rfmng plmin
                    from vbfa into table int_records2
                                  for all entries in int_Records1
                                  where vbelv = int_records1-vbeln
                                    and posnv = int_records1-posnr
                                    and VBTYP_N = 'J'. "Dels
    *calculate open quantities next
         loop at int_records1.
           clear wlf_lmeng.
           clear int_records2.
           loop at int_records2 where vbelv = int_records1-vbeln
                                    and posnv = int_records1-posnr.
           case int_records2-plmin.
             when '-'.
              wlf_lmeng = wlf_lmeng - int_records2-rfmng.
             when others.  "just add
              wlf_lmeng = wlf_lmeng + int_records2-rfmng.
            endcase.
           endloop.
           int_records1-klmeng = int_records1-klmeng - wlf_lmeng.
           int_records1-vbeln_dl = int_records2-vbeln.
           int_records1-posnr_dl = int_records2-posnn.
           modify int_records1.
        endloop.
        endif.
        delete int_records1 where klmeng le 0.
        refresh int_records2. free int_Records2.
    ENDFORM.                    " get_data
    *&      Form  build_detail
          text
    -->  p1        text
    <--  p2        text
    FORM build_detail.
        LOOP AT int_records1.
    *DO INDIVIDUAL MOVES - ITS FASTER THAN MOVE-CORRESPONDING
        move: int_records1-vkorg    to LS_DATA-VKORG,
              int_records1-werks    to LS_DATA-WERKS,
              int_records1-matnr    to LS_DATA-MATNR,
              int_records1-klmeng   to LS_DATA-KLMENG,
              int_records1-mbdat(6) to LS_DATA-YEARMONTH,
              int_records1-meins    TO LS_DATA-MEINS,
              int_records1-vbeln    TO LS_DATA-VGBEL,
              int_records1-posnr    TO LS_DATA-VGPOS,
              int_records1-vbeln_dl TO LS_DATA-VBELN,
              int_records1-posnr_dl TO LS_DATA-POSNR,
              int_records1-mbdat    to LS_DATA-WADAT_IST,
              int_records1-PRDHA    to LS_DATA-PRDHA,
              int_records1-matkl    to LS_DATA-MATKL.
        APPEND LS_DATA TO LT_DATA.
        clear: LS_DATA.
        ENDLOOP.
    ENDFORM.                    " build_detail

  • CAL TRANSACTION ' QE51N' USING BDCDATA

    Dear all,
    i have problem in the transaction QE51N, i explain:
    The objective of my program Z is to call  the QE51N and to fill one of his select-options with values which I already recovered in the progam  Z.
    Now all is Ok, I could fill the table BDCDATA with the valuesu2026 and I called the QE51N using CAL TRANSACTION ' QE51N' USING BDCDATA
    Currently ==> when I save in the QE51N  I turn over to the special program (thing which I dont  want) 
    I want to leave completely the program and to remain that in the QE51N.
    I tested " LEAVE PROGRAM" after the CAL TRANSACTION but that made leave the program and the QE51N.
    there is a possibility to do that?
    NB: SUBMIT PROGRAM ==KO because the program of the QE51N is of type module pool. 
    Thanks in advance
    Edited by: Abaper_R3 on Jan 23, 2010 3:46 PM

    To remain on the last screen of a CALL TRANSACTION, you must call it using MODE 'E'.
    If it doesn't stop, it probably means that there is an issue with the existing CALL TRANSACTION which doesn't even reach the last screen: call it with MODE 'A' to make sure (it displays all screens). If it reaches the last screen using MODE 'A', then there are 2 possibilities why it doesn't reach it in MODE 'E' (or 'N'):
    1) Either there is an intermediate COMMIT WORK which stops the CALL TRANSACTION (solution is then to use OPTIONS FROM <structure> and set <structure>-RACOMMIT = 'X' (request to not stop the CALL TRANSACTION if a COMMIT WORK is reached)
    2) or the program detects that the transaction is called using CALL TRANSACTION and reacts differently. If the program tests SY-BINPT, then you may run the program use OPTIONS FROM <structure> and set <structure>-NOBINPT = 'X'). If the program tests other things (SY-CPROG, SY-CALLD, etc.), then the only possiblity is probably a modification of the standard!
    Of course, all this is explained in the ABAP documentation of CALL TRANSACTION.

  • Partition by range using greater than or in between statment?

    Can you partition by range using greater than or in between statment? If so, can someone please post the syntax?

    ji**** wrote:
    Can you partition by range using greater than or in between statment? If so, can someone please post the syntax?http://download.oracle.com/docs/cd/B10500_01/server.920/a96524/c12parti.htm
    CREATE TABLE sales_range
    (salesman_id  NUMBER(5),
    salesman_name VARCHAR2(30),
    sales_amount  NUMBER(10),
    sales_date    DATE)
    PARTITION BY RANGE(sales_date)
    PARTITION sales_jan2000 VALUES LESS THAN(TO_DATE('02/01/2000','DD/MM/YYYY')),
    PARTITION sales_feb2000 VALUES LESS THAN(TO_DATE('03/01/2000','DD/MM/YYYY')),
    PARTITION sales_mar2000 VALUES LESS THAN(TO_DATE('04/01/2000','DD/MM/YYYY')),
    PARTITION sales_apr2000 VALUES LESS THAN(TO_DATE('05/01/2000','DD/MM/YYYY'))
    );

  • How to count the days between Date Range using OO ABAP?

    hi experts,
            i want to count the days between Date Range using OO ABAP for that  which class and method  can i use?.
    Thanks,
    Mahesh.

    Not sure I understand the requirement for it to be OO, but you could always write your own (i.e. use this):
    REPORT zz_date_diff.
    CLASS date_diff DEFINITION.
      PUBLIC SECTION.
        METHODS diff IMPORTING     i_date_fm TYPE d
                                   i_date_to TYPE d
                     EXPORTING     e_days    TYPE i.
    ENDCLASS."
    CLASS date_diff IMPLEMENTATION.
      METHOD diff.
        e_days = i_date_to - i_date_fm.
      ENDMETHOD."
    ENDCLASS."
    DATA: g_ref TYPE REF TO date_diff,
          g_days  TYPE i,
          g_date_fm  TYPE d VALUE '20080101',
          g_date_to  TYPE d VALUE '20090101'.
    START-OF-SELECTION.
      CREATE OBJECT g_ref.
      CALL METHOD g_ref->diff
        EXPORTING
          i_date_fm = g_date_fm
          i_date_to = g_date_to
        IMPORTING
          e_days    = g_days.
      WRITE g_days.

  • Message type in BDCMSGCOLL Structure in Call transaction using BDCDATA

    Hi,
    We are facing issue while capturing message in BDCMSGCOLL structure in Call transaction using bdcdata. The message which are like
    Message 'Message Text' Type 'S' Display LIke 'E' .
    This message is captured as Success on the Message structure instead of error & user are asking to update it as Error as it is looking like Error message to the end user.
    Please provide resolution to the issue.
    Regards,
    Kapil

    Hi Venkat,
    I am not doing any upload, i am just doing a replay of the transaction ME21 & in that there are many error message which encounter while creating a PO but when i have check the logic , they are basically a success message which are display like Error so when i have called ME21 transaction using below statement
    call transaction ME21 using BDCDATA
                                            into messages bdcmsgcoll.
    I am getting the message as success only since the message are of type success but as they are display like E , so user want that in msgcoll structure these messages must be shown as Error.
    Regards,
    Kapil.

  • FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 601 instead.

    I changed the value to MTTR yesterday i am getting these messages at alert log
    Can any body tell me figure i shuould set for it
    Wed Feb 8 07:02:45 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 601 instead.
    Wed Feb 8 07:05:46 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 602 instead.
    Wed Feb 8 09:03:58 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 601 instead.
    Wed Feb 8 10:02:48 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 602 instead.
    Wed Feb 8 10:05:19 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 603 instead.
    Wed Feb 8 11:04:11 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 604 instead.
    Wed Feb 8 12:03:01 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 605 instead.
    Wed Feb 8 13:03:22 2006
    FAST_START_MTTR_TARGET 600 is out of the valid MTTR range, use 606 instead.

    I made you a suggestion. It is a bug. Open a TAR. Or go by trial and error method increasing FAST_START_MTTR_TARGET until you stop getting messages
    Vadim Bobrov
    Oracle Database Tools
    http://www.fourthelephant.com

  • AFAB:AA776 "Create document number range ## using internal number assignmen

    Good afternoon
    I ask for your guidance to see if anyone knows me that is generating errors in the transaction AFAB AA776 "Create document number range ## using internal number assignment", the peculiarity of this is that I'm in an environment that is proving to migrate V5 to V6 ranges in environment QAS is marked as external and no problems to run on v6 change in SAP itself. Test by removing the flag marking for external control and run, causing an alarm is that it does not work as in my QAS v 5 and that I should remove this flag is removed and remove it in all the years this range of numbers is that it can hurt if you make this change.
    Can anyone guide me please.
    Thanks for the support.
    good day

    Hello ,
    Kindly have a look at the below  notes that will help you resolve the
    issue :
    890976 - Converting closing report to internal doc number assgnmnt
    If note 890976 has been applied in your system already (package
    level is = or > SAPKH60005), so what you need to check is the
    following :
    In transaction FBN1, in your company code  you should see that the
    period and number range in question is ticked as external.
    Please untick the indicator for "External" and press enter. If this
    box happens to be uneditable then untick the number range for the
    previous year and press enter. All other entries will update
    automatically.
    Here is a brief explaination to why this change has been made:
    Before ERP2005(RAPOST2000 exists as of release 4.70)the number usage
    was external, because RAPOST2000 internally managed the document number
    handling. As this was not possible any more with the New General Ledger
    functionality, and as the usage of internal number ranges is much
    simpler and more efficient, we changed the number range management
    inside RAPOST2000 (and by the way also the new periodic posting report
    RAPERB2000).
    Please kindly check the attached notes 683313 for your reference.
    I hope this provides some clarification.
    regards
    Ray

  • Loading a range using macro

    Hello,
    I have once come across a technique of loading a range using a macro that was stored in table TRMAC.  Has anyone seen anything similar to this?  I copied the code to a jump drive but have misplaced it.  It was really a cool way to load a range with individual values.
    Thanks,
    Joe

    You don't have to store it in that TABLE.  You can define the macro in your program.
    ranges: r_datum for sy-datum.
    Define build_range.
    r_datum-sign = 'I'.
    r_datum-option = 'EQ'.
    r_datum-low = &1.
    append r_datum.
    end-of-definition.
    * Now use the macro
    build_range sy-datum.
    Regards,
    Rich Heilman
    Message was edited by: Rich Heilman

  • I have a net gear router supplied by virgin media. Can I extend my wi-fi range using express or extreme?

    I have a net gear router supplied by virgin media. Can I extend my wi-fi range using express or extreme?

    Apple designed their "extend" feature with proprietary settings to only work with other Apple routers.
    As a consequence, there is virtually no chance that the Apple devices you mention would extend the signal of a non-Apple wireless router...using wireless only.
    If you plan to connect the Apple devices back to your Virgin Media router using a permanent wired Ethernet cable, you can configure the AirPorts to provide more wireless coverage that way.

  • Scan and fill form using Acrobat 6.0

    How can I scan hardcopy of a form, save as PDF, open the form in Acrobat 6.0, and fill in the blanks (fields)?

    Thanks Dave.
    I'm aware that my 6.0 acrobat is way out of date.  But I thought I created a fillable form a few years ago using it.  But in that case it probably was a PDF going into the process, not a scanned form.  Also, I was using vista at the time and now have win 7/64bit.
    I'll try the OCR routine but your post suggests what I suspected, that I can't get to where I'm going from here.
    Date: Tue, 25 Mar 2014 19:27:21 -0700
    From: [email protected]
    To: [email protected]
    Subject: Scan and fill form using Acrobat 6.0
        Re: Scan and fill form using Acrobat 6.0
        created by CtDave in Creating, Editing & Exporting PDFs - View the full discussion
    As Acrobat 6 went out of support / obsolete many years ago you'll want to be sure the OS is compatible and the scanner software is compatible.
    Use Acrobat's create PDF from scanner feature (review the Help file if needed, the Help PDF was installed when Acrobat 6 was installed).
    So, you'll now have that PDF.
    But, it is not yet a form PDF.
    The scanner output is an image so you have an image / a picture as the PDF page content.
    You may want to use Acrobat's OCR feature to provide a hidden layer of renderable characters.
    Use Acrobat's form tools to build your form. As Acrobat 6 is long ago gone by I don't recall if it had a "form wizard". Check the Help PDF.
    Be well...
         Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/6242371#6242371
         Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/6242371#6242371
         To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/6242371#6242371. In the Actions box on the right, click the Stop Email Notifications link.
               Start a new discussion in Creating, Editing & Exporting PDFs at Adobe Community
      For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0.

  • Ranges using subroutines

    Hi All,
    i have 20 parameters in Fm. if i pass any value in those parameters , the Fm should return the entries matching to that value. If i dont pass any value in params, the FM should return all the values . To achive this i have defined ranges for all 20 parameters and when those params have the value i am filling a range objects with values. If params not conatins any value am just not doing any thing.
    Here my question is i want to fill this range objects using perform statement. I dont want to write 20 times. So i have created one subroutine passing range object as table and remaining values in USING statement. Here i am getting one error that range object is too big to hold the value.
    MY perform statement is
    perform range tables r_matnr
                          using 'I'
                                   'EQ' 'lowvalue'.
    form ranges tables p_r_matnr structure range_matnr
                              using p_i
                                       p_eq
                                      p_low.
    endform.
    can any one please tell me how to fill the range object dynamically, for example if the range object is werks then in the form statement structure i want to refer werks range.
    Thanks,
    CS Reddy.

    Hi,
         Pass the data using TYPE REF TO DATA.
    DATA: lt_tab TYPE TABLE OF <some_type>.
    DATA: data_ref TYPE REF TO DATA.
    GET REFERENCE OF lt_tab INTO data_ref.
    perform routine USING data_ref.
    form routine p_data_ref TYPE REF TO DATA.
    DATA: l_tab TYPE TABLE OF <some_type_same_as_above>.
    l_tab = p_data_ref->*.
    endform.
    Best Regards,
    Sesh

  • Call transaction CJIC using bdcdata and skip first screen

    I want to call transaction CJIC and skip first screen. I have set parameters for fields for which I need to pass data. But one field namely display variant has no parameter id. How can I pass value to it and also skip first screen?
    I have tried passing its value in bdcdata and also passing ONLI. But it does not run in mode "N". What can be the solution?

    Hi frnd,
    fortunately transaction CJIC is selection-screen of an executable program RKPEP012.......so u don hav to use call transaction and instead u can use SUBMIT statement................
    submit RKPEP012 WITH SELECTION-TABLE rspar
    Effect
    If you specify this addition, parameters and selection criteria on the selection screen are supplied from an internal table rspar. You must specify an internal table with the row type RSPARAMS for rspar. The structured data type RSPARAMS is defined in the ABAP Dictionary and has the following components, all of which are data type CHAR:
    SELNAME (length 8),
    KIND (length 1),
    SIGN (length 1),
    OPTION (length 2),
    LOW (length 45),
    HIGH (length 45).
    To supply parameters and selection criteria for the selection screen with specific values, the lines in the internal table rspar must contain the following values:
    SELNAME must contain the name of a parameter or selection criterion for the selection screen in block capitals
    KIND must contain the type of selection screen component (P for parameters, S for selection criteria)
    SIGN, OPTION, LOW, and HIGH must contain the values specified for the selection table columns that have the same names as the selection criteria; in the case of parameters, the value must be specified in LOW and all other components are ignored.
    If the name of a selection criterion is repeated in rspar, this defines a selection table containing several lines and passes it on to the selection criterion. If parameter names occur several times, the last value is passed on to the parameter.
    The contents of the parameters or selection tables for the current program can be entered in the table by the function module RS_REFRESH_FROM_SELECTOPTIONS.
    Notes
    In contrast to selection tables, the data types of the components LOW and HIGH in table rspar are always of type CHAR and are converted to the type of the parameter or selection criterion during transfer, if necessary.
    When entering values, you must ensure that these are entered in the internal format of the ABAP values, and not in the output format of the screen display.
    Revert back for queries.
    Cheers,
    Will.

  • How do you get auto fill to use the right E-mail address?

    Hi Everyone
    My address book card has multiple E-mail addresses on it. Yet when I want to use auto fill to fill out a form, 100% of the time it's just one address I want to use. The problem is safari always uses only one of the addresses and it's not the one I want to use. Is there a way to change which address (or any other field) from your address card is used in auto fill?
    TIA
    K

    Since you don't say how many email addresses you have on your own card or which of them it's picking, I'll assume it's choosing the first one in the list. If that's correct and it's not the one you want, you need to change the order of addresses to make the one you want be the first one in the list.
    Other than that, you cannot set a default item for any field.
    Mulder

  • Data set in Data not fill properly using ODP(Oracle.DataAccess.dll 64bit)

    public void BindFun()
                OracleParameter[] o_OracleParameters;
                OracleConnection o_Connection = new OracleConnection(VRODPConnection());
                OracleCommand o_OracleCommand = new OracleCommand();          
                OracleDataAdapter o_OracleDataAdapter;    
                DSSearchResults = new DataSet();
                // Narendra : 03/11/2014
                o_OracleParameters = new OracleParameter[16];
                o_OracleParameters[0] = new OracleParameter("iv_LastName", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[0].Value = "";
                o_OracleParameters[1] = new OracleParameter("iv_FirstName", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[1].Value = "";
                o_OracleParameters[2] = new OracleParameter("iv_MiddleName", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[2].Value = "";
                o_OracleParameters[3] = new OracleParameter("iv_MotherMaidenLastName", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[3].Value = "";
                o_OracleParameters[4] = new OracleParameter("v_SearchRangeFrom", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[4].Value = "01-01-2014";
                o_OracleParameters[5] = new OracleParameter("v_SearchRangeTo", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[5].Value = "12-01-2014";
                // "01-12-2014";//Narendra 04/11/14 14:17//
                o_OracleParameters[6] = new OracleParameter("v_RecordTypeId", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[6].Value = "2,4,5";
              // IN this
                o_OracleParameters[7] = new OracleParameter("v_PagingRequired", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[7].Value = 1;
                o_OracleParameters[8] = new OracleParameter("v_PageNum", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[8].Value = 1;
                o_OracleParameters[9] = new OracleParameter("v_PageSize", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[9].Value = 1000;
                o_OracleParameters[10] = new OracleParameter("v_SortFieldName", OracleDbType.Varchar2, ParameterDirection.Input);
                o_OracleParameters[10].Value = "VitalRecordsLastName";
                o_OracleParameters[11] = new OracleParameter("v_Sealed", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[11].Value = 1;
                o_OracleParameters[12] = new OracleParameter("v_CurrentRecordsOnly", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[12].Value = 0;
                o_OracleParameters[13] = new OracleParameter("v_AccessID", OracleDbType.Int32, ParameterDirection.Input);
                o_OracleParameters[13].Value = 5;
                o_OracleParameters[14] = new OracleParameter("v_TotalRecs", OracleDbType.Int32, ParameterDirection.Output);
                o_OracleParameters[14].Value = 0;
                o_OracleParameters[15] = new OracleParameter("pResult", OracleDbType.RefCursor);
                o_OracleParameters[15].Direction = ParameterDirection.Output;
                o_Connection.Open();
                o_OracleCommand.Connection = o_Connection;
                o_OracleCommand.CommandText = "VR_AllGeneral_Search";
                o_OracleCommand.CommandType = CommandType.StoredProcedure;
                o_OracleCommand.Parameters.AddRange(o_OracleParameters);      
                o_OracleDataAdapter = new OracleDataAdapter(o_OracleCommand);o_OracleDataAdapter.Fill(DSSearchResults);
               dataGridView1.DataSource = DSSearchResults.Tables[0];
                o_Connection.Close();
                o_Connection.Dispose();
              // 2 pass than ans total record =127 than after pass 4 ans =413 than after 5 ans=413
              // 4 pass than ans total record =286 than after pass 2 ans =413 than after 5 ans=413
               // 5 pass than ans total record =0 than after pass 2 ans =127 than after 4 ans=413
    What is the problem of above code pls info 

    Hi,
    but when i install oracle express edition 10g on that machine i am able to connect to the remote database
    Does the client machine have an Oracle Client installed before you do this at all? An Oracle Client is required in some fashion to use ODP.NET - either a full-client or the instant client if you are using a version that supports instant client.
    - Mark

Maybe you are looking for

  • I NEED HELP DOWNLOADING PURCHASED ITEMS FROM ICLOUD

    "You can download past purchases on this computer with just one Apple ID every 90 days" is the message i keep getting on my screen when i try to download my TV shows from icloud. I dont understand why I cannot down load stuff. Someone, kindly explain

  • Can't Save Application State in Acrobat X Pro

    There once was a time that I could close Acrobat X Pro with various and sundry pdfs open and upon reopening the application, those selfsame documents would reappear. This is no longer the case, and I have no idea what has changed. I am using Acrobat

  • Plugin for a sort of color palette

    Hello everybody, is there a plugin or a feature in Photoshop CS6 I haven't discovered yet that offers me a sort of color palette that looks like the 'Color' feature in the 'Window' menu in Adobe Illustrator CC 2014? The palette offered by the plugin

  • Canon 7D MRaw & SRaw not recognized in ACR 5.5

    Hi, I was testing the Canon 7D MRaw and SRaw, but ACR 5.5 does not read them.  It does read the full RAW file.  Will these be supported soon? Thanks,

  • HT201303 how can I print a receipt for an apps store purchase

    How can I print a receipt for apps purchased on my phone?