Selections conditions at the Infopackage

Hi,
My Requirement is to load data for the selection conditions of Current month+12 periods and Current Month-24 periods for the Calmonth characteristic by writing a routine at the infopackage level.
Is there any standared function module for caluclating the year and period using the system date.
If I use 'DATE_TO_PERIOD_CONVERT' then this would give me the year and period but that needs my fiscal variant.
Could some pne help me with this.
Regards,
Vamsi

Hi Ajay,
Could you please tell me whether this code works out for +12 months..
Data : today like sy-datum,
      current_month(6)  type C,
       I_MONTH    TYPE I,
      I_YEAR     TYPE I.
     data: l_year like T009B-BDATJ,
      l_period like T009B-POPER.
data: l_fiscperlow like l_t_range-low.
data: l_fiscperhigh like l_t_range-high.
  today         = sy-datum.
  current_month = today+0(6).
  l_year        = today+0(4).
  l_period      = today+4(2).
l_fiscperlow = current_month.
    Add 1 to l_year.
        concatenate l_year l_period+1(2) into l_fiscperhigh.
      l_t_range-low = l_fiscperlow.
      l_t_range-high = l_fiscperhigh.
      l_t_range-option = 'BT'.
      l_t_range-sign = 'I'.
Regards,
Vamsi

Similar Messages

  • Selection condition in the infopackage for initializing delta

    How does the selection condition in the infopackage help in initializing delta?

    Hi,
    You can enter multiple single valus for any field in the infopackage. Just select the row for material type and then click on the insert duplicate button ( + sign ) which is at the bottom letf hand side in the 'Data Selection' tab within the infopackage. You will usually find this 'insert duplicate' icon next to the 'Check' push button.
    You can insert as many rows as you want for material type by select the material type rown and clicking on this icon. You can then enter the three values in the three rows for material type.
    Regards,
    Shilpa

  • SV004 - I need to change the selection condition in the view: J_1BT001W

    Hello guys,
    Can you please help me with a topic ?
    How can I change the selection condition in the view: J_1BT001W ?
    I was trying to use se11, but says that J_1BT001W does not exist.
    Thanks a lot,
    Jordan

    Hi Jordan,
         The correct view name is J_1BT001WV and not J_1BT001W. It is made of table joins - T001W T001K T005. Please let me know if this answers your question.
    Regards
    Ram

  • Selection in the Infopackage for multiple values...

    In the Selection package of the Infopackage(full mode) , I want to restrict the selection of the data to three values out of all the values.
    Is it possible.
    I cant give it in the From and To , its not in sequence.
    The field for which I want to select the data is Material Type.
    Please let me know.
    Thanks , jeetu

    Hi,
    You can enter multiple single valus for any field in the infopackage. Just select the row for material type and then click on the insert duplicate button ( + sign ) which is at the bottom letf hand side in the 'Data Selection' tab within the infopackage. You will usually find this 'insert duplicate' icon next to the 'Check' push button.
    You can insert as many rows as you want for material type by select the material type rown and clicking on this icon. You can then enter the three values in the three rows for material type.
    Regards,
    Shilpa

  • CostCenter Hierarchy selection in the Infopackage

    Hi Everyone,
    For CostCenter hierarchy, in the Infopackage Hierarchy Selection tab, I can able to find the Parent Node for loading, but there is no Child node available.
    Can anyone help on how to bring the child node into the Hierarchy selection tab, and also how to check the Hierarchy node in ECC side.
    Thanks in advance,
    Satish.

    Hi,
    You can enter multiple single valus for any field in the infopackage. Just select the row for material type and then click on the insert duplicate button ( + sign ) which is at the bottom letf hand side in the 'Data Selection' tab within the infopackage. You will usually find this 'insert duplicate' icon next to the 'Check' push button.
    You can insert as many rows as you want for material type by select the material type rown and clicking on this icon. You can then enter the three values in the three rows for material type.
    Regards,
    Shilpa

  • Variant Configuration: Selection Conditions in BOM

    Hi Experts,
    I am trying to insert more than one selection condition in the BOM. But the system only takes one of this conditions.
    For example I want to have two objects dependencies:
    Selection Condition 1: Engine = 2
    Selection Condition 2: Colour = 'Red'
    instead of
    Selection Condition xy: Engine = 2 and Colour = 'Red'
    Is it possible to use more than one and how can I handle with this. Or is that not possible
    The  system doesn't take the two conditions at the moment...
    What can I do to solve this?
    Thank for your answers,
    Marc

    Hi,
    yes I am talking about object dependency. Especially about selection conditions.
    I want to select the required BOM positions out of the super BOM.
    For that, I have to define this dependencys. But as I mentioned before, only one of the two dependencys gets read and the wrong BOM positions comes out of the explosion.
    Have you any other ideas how to handle with this?
    Thanks a lot.
    Marc

  • Query on resource selection condition

    Hi All
    I have a process order with a operation having a resource selection condition.In the classification of the master recipe i have entered the resource name(as characteristic value) as X whereas the name of the resource where the operation is to take place is A and in the classification of the resource A i have enter the characteristic value as "A".
    Now is it possible to release the process order without getting the error message :"Resource in operation does not satisfy resource selection condition".
    please advice.

    Hy,
    Kindly go through below link it might be give some inputs if some data is missing in your condition.
    [http://help.sap.com/erp2005_ehp_03/helpdata/EN/89/a42678461e11d182b50000e829fbfe/frameset.htm]
    Regards,
    Dhaval

  • Selection Condition In Infopackage

    Hello,
      Is there a way to use a single infopackage by passing different selection conditions thru' abap routine, for delta init.  We require this as we have to extract data based on the logged-in user.
      Any help is highly appreciated.
    Thank you very much,
    Raj

    Hi Ronald,
    I am coming back with further infn after a long time as i was strucked with other development area, actually our client requirement is Data has to be loaded on company wise .. means the respective responsible person only carryon loading person as per his profile(Authorisation)load has to be happen...this is one requirement,
    one more is (whether in this scenario can we go for Delta)
    we enhanced the Dtasource with new field in R/3 and when we are trying to make it selction condition in infopackage we are not getting filtering as per that ..
    could u or anyone who knows through a light on this..
    Thanks in advance
    BRB

  • ABAP routine in the infopackage for Multiple Selection

    Hi experts,
    I want to include a abap routine in the infopackage for Multiple Selection so that I can fetch only the required Material Numbers when the InfoPackage is schedule. As I have the constraints that I have to select certain Material Numbers only, that are not in series - so I cannot select"BT' fuction. Tell me what ABAP Code will work in this scenario.
    Kind regards,
    Rajesh Giribuwa

    Hi,
    The Routine will have to use 'EQ' operator and Append each selections to the Structure.
    ABAP Routine
    InfoPackage definition for Bespoke SIS Structure
    Infopackage routine !
    Regards
    Happy Tony

  • Adhoc Query : Error during selection; check the selection conditions

    Hi
    We have a report set-up and which we want to run using our adhoc query report tcode S_PH0_48000513
    The report, has a few different selection criteria in it to look at all action IT screen data in the system for ee's in specific personnel areas. There is also a criteria to allow us to paste in specific employee numbers we are interested in. The issue I am facing is that over about 3000 ids, the system automatically returns me a message when I click on the Output button to run the report which states:
    Error during selection; check the selection conditions
    Message no. PAIS206
    I am not sure why this is happening. The selection criteria are fine and the other day I ran the report and I experienced no issues. The report ran successfully. Now though, if I try and paste in all the ids I am interested in (about 8000) I get this message straightaway.
    Can anything be done to overcome this issue?
    Any advice would be much appreciated.
    Nicola

    Hi
    The message in full is:
    Error during selection; check the selection conditions
    Message no. PAIS206
    Diagnosis
    A runtime error occurred during dynamic selection.
    System response
    The runtime error will be caught; no short dump will be created. This error should not occur as a rule. However, very large select statements may trigger the runtime error SAPSQL_STMNT_TOO_LARGE or DBIF_RSQL_INVALID_RSQL. There is no way to prevent this happening. In this case, the error can only be caught.
    Procedure
    Check the selection conditions to see whether the error was caused because the option "Import from text file" included too many objects in the "Multiple selection" dialog. If this is so, you must limit the number of individual values.

  • ABAP Routine in the Infopackage data selection

    All,
    I have requirement where i need to write a routine on a Date field(Activity Year Month) which has to return values from the first to the last day of the Previous month in the data selection of the infopackage.
    I know that on Date there is a STD that can be used but my requirement is on Year Month.
    there are 3 vartypes available
    5. free temporal selection
    6. ABAP routine
    7. OLAP variable
    when i pick ABAP routine it asks me to create a routine i need some help with the code here
    Can someone help.
    Thanks

    Hi there
    If the Data field is 0FISCPER you can use the OLAP variable 0P_PRFP1. If you have developed the field yourself i think you need to write code. The code could look something like this.
    DATA:  sysdat TYPE d.
      sysdat = sy-datum.
      sysdat4(2) = sysdat4(2) - 1.
      IF sysdat+4(2) = '0'.
        sysdat+4(2) = '12'.
        sysdat(4) = sysdat(4) - 1.
      ENDIF.
      CONCATENATE sysdat(4) '0' sysdat+4(2) INTO l_t_range-low.
      MODIFY l_t_range INDEX l_idx.
      p_subrc = 0.
    This code returns the previous months as a single value.
    Chris

  • I need use conditions in the select fields of a query.

    Hello,
    Is possible, that I can have conditions in the select fields of a query? In a invoice when the type is cancellation I want to put *-1 to price and if is other type the price is normally.
    If VBRK.FKART = 'S1' THEN KWERT*-1 else KWERT .
    Thank you very much.

    you can do two things:
    1. select the data into internal table and loop through the internal table and do the necessary changes
    SELECT fkart kwert
    FROM vbrk
    INTO TABLE itab
    WHERE ...
    LOOP AT itab.
    IF itab-fkart EQ 'S1'.
    itab-kwert = itab-kwert * -1 .
    MODIFY itab.
    ENDIF.
    ENDLOOP.
    2. use select-endselect and change the data acc. to your needs inbetween and append the internal table.
    SELECT fkart kwert
    FROM vbrk
    INTO wa
    WHERE ...
    IF wa-fkart EQ 'S1'.
    wa-kwert = wa-kwert * -1 .
    ENDIF.
    APPEND wa TO itab.
    ENDSELECT.
    (The first approach is probably faster.)

  • To Value not highlighting in the Infopackage Selection

    Hi All,
    I am extarcting the data from the IS-Utilities(R/3) to the BI system, my datasource is 0UC_EDM_02, in the Infopackage - dataselection for the Profile infoobect, it is highlighting only the FROM Value and TO Value it is not highlighting,
    I checked in the datasource 0UC_EDM_02,  the Profile field is used as selection field,
    but in the infopackage, TO value is not highlighting, i need range of values to be given in the infopackage,
    Please, suggest on this
    Thanks
    Prasad

    Hi,
    When I created infopackage , in the Data selection tab, I had the Infoobject named Profile, I need to give the range(FROM & TO Values to extract the particular data) of Input ,
    but, FROM value , I could give Input and TO Value it is not active or not highlighting to insert some Profile Value,
    Please, let me know , if U r not clear about this,

  • How to speed a select statement with the NOT EXISTS where condition ?

    Hi all,
    I created a view : create or replace view view_name as select * from table_1,table_2 where join_condition and some conditions.
    Now I have added in the view "where" clause two NOT EXISTS conditions based on one another different table respectively.
    Before I added these two conditions the response time was fast ; but after I added these two conditions then the response time deteriorated.
    So how to optimize the select statement ? Hints and so on ...
    Thank you very much indeed
    Message was edited by:
    andrianiaina

    Just run the script :
    SQL> explain plan for select * from dual;
    Explained.
    SQL> @$ORACLE_HOME/rdbms/admin/utlxpls.sql
    PLAN_TABLE_OUTPUT
    | Id  | Operation            |  Name       | Rows  | Bytes | Cost  |
    |   0 | SELECT STATEMENT     |             |       |       |       |
    |   1 |  TABLE ACCESS FULL   | DUAL        |       |       |       |
    Note: rule based optimization
    9 rows selected.
    SQL>Nicolas.

  • NOT EQUAL in the InfoPackage Data Selection

    Hello,
    <u><b>I need to build a NE, NOT EQUAL <>  in an InfoPackage</u></b>
    I need to exclude some DataSets from beeing loaded.
    The DataSets to be excluded can be distinguished by a
    certain value of a an InfoObject.
    For example:
    All DataSets with  0COMPANY_CODE NOT EQUAL "0001" should not
    be loaded.
    How can I set in the InfoPackage DataSelection a filter
    to exclude some DataSets ?
    Thank You
    Martin Sautter

    Hello Chitrarth Kastwar ,
    basically it would be a trivial task in SQL ....to code :
    <i>
    SELECT *
    FROM
    WHERE  0COMP_CODE not in '0001'
    </i>
    or
    <i>
    SELECT *
    FROM
    WHERE  0COMP_CODE =  '0030'
    OR          0COMP_CODE =  '0040'
    OR          0COMP_CODE =  '0050'
    </i>
    .. but thats BW  - It generates much turnaround for consultants :).
    Thread
    /community [original link is broken] threadID=507511&tstart=0
    seems to be something like this.
    ...I get the following Conversion Routine for Type 6:
    <i>
    program conversion_routine.
    Type pools used by conversion program
    type-pools: rsarc, rsarr, rssm.
    tables: rssdlrange.
    Global code used by conversion rules
    $$ begin of global - insert your declaration only below this line  -
    TABLES: ...
    DATA:   ...
    $$ end of global - insert your declaration only before this line   -
        InfoObject      = ZVPUNITH
        Fieldname       = /BIC/ZVPUNITH
        data type       = CHAR
        length          = 000045
        convexit        =
    form compute_/BIC/ZVPUNITH
      tables   l_t_range      structure rssdlrange
      using    p_infopackage  type rslogdpid
               p_fieldname    type rsfnm
      changing p_subrc        like sy-subrc.
          Insert source code to current selection field
    $$ begin of routine - insert your code only below this line        -
    data: l_idx like sy-tabix.
              read table l_t_range with key
                   fieldname = '/BIC/ZVPUNITH'.
              l_idx = sy-tabix.
              modify l_t_range index l_idx.
              p_subrc = 0.
    $$ end of routine - insert your code only before this line         -
    endform.
    </i>
    Because I have to exclude 1 value out of 5 I can also include 5 values in the
    selection criteria connected with OR
    This means I have to use an OR only.
    Is it possible with l_t_range to state this and how ?
    Thank You
    Martin Sautter

Maybe you are looking for