******Creation of a loading selection for cube in info package level

Hi,
when we are  scheduling the info package(Infp package name is like XYZ),we want to load past 6 months data from the current date(INFO OBJECT(0CREATEDON) BETWEEN (Sy-Datum - 6 months TO  Sy-Datum),in the selection tab in schedule i want to write the abap routine (type 6).please can any one have this type of code please sedn to me asap.
this is very urgent.delivery is tomorrow.
Regards
lekha

hi Lekha,
try
data: l_idx like sy-tabix,
l_month(6) type c,
l_dtlast6month like sy-datum.
read table l_t_range with key
iobjnm = '0CREATEDON'.
l_idx = sy-tabix.
DELETE l_t_range
WHERE iobjnm = '0CREATEDON'.
L_t_RANGE-SIGN = 'I'.
L_t_RANGE-OPTION = 'EQ'.
if not work, try
L_t_RANGE-OPTION = 'BT'.
BT = between
current month
concatenate sy-datum3(2) sy-datum0(4) into l_month.
L_t_RANGE-HIGH = l_month.
last 6 month
clear l_month.
l_dtlast6month = sy-datum - 180.
concatenate l_dtlast6month4(2) l_dtlast6month0(4) into l_month.
L_t_RANGE-LOW = l_month.
append l_t_range.
modify l_t_range index l_idx.
p_subrc = 0.
$$ end of routine - insert your code only before this line -
endform.
Re: routine as selection in infopackage
Re: routine as a selection in infopackage 2. Paolo Siniscalco and A.H.P
Re: abap routine

Similar Messages

  • Routines for File name at External Data in Info Package level.

    Hi All,
    Can any one give the example codes of how to write the routine for Files at External Data in Info Package level.
    Regards
    srinivas

    Hi Srinivas
    Here iam attaching a sample code in the infopackage level this code is used to select the Current version from TVARV table ..based on the version from variable the data is loaded into the ods..
    data: l_idx like sy-tabix.
              read table l_t_range with key
                   fieldname = 'FISCPER'.
              l_idx = sy-tabix.
    tables tvarv.
    data: v_prever(6)   type c,
          v_fiscper(7)  type n.
      clear tvarv.
      select single low
       from tvarv
       into v_prever
      where name = 'ZBSK_PREVIOUS_RELEASED_VERSION' and
            type = 'P' and
            numb = '0000'.
    concatenate v_prever(4) '0' v_prever+4(2) into v_fiscper.
       concatenate  '0' v_prever+4(2) v_prever(4) into v_fiscper.
            l_t_range-low = v_fiscper .
              modify l_t_range index l_idx.
    Hope the above code helps you..
    let me know in case of any concerns.. and further help needed..
    bye
    Shu Moh..

  • Delta and Full Load question for cube and ODS

    Hi all,
    I need to push full load from Delta ODS.
    I have process chain.... in which the steps are like below,
    1. R/3 extractor for ODS1 (delta)
    2. ODS1 to ODS2 (delta)
    3. ODS2 to Cube ---> needs to be full load
    Now when i run process chain by further processing automatically ODS2 does init/delta for Cube.
    How can i make it possible for full load ??
    can any one guide anything in this ?
    Thanks,
    KS

    Hi,
    1. R/3 extractor for ODS1 (delta) :  This is OK, normally you can put the Delta InfoPack in Process Chian
    2. ODS1 to ODS2 (delta): It automatically flow from ODS1 to ODS2 (you need to select Update Data automaticall in the Targets at the time of ODS creation)
    3. ODS2 to Cube ---> needs to be full load  :
    This you create a Update rules from ODS1 to Cube then Create InfoPackage in between ODS2 and Cube then do full loads. You can delete the data in the CUbe before the load ann dthen do Full load to Cube.
    Note: In ODS2 don't select Upadate Data autmaticlly to Data Targets
    Thanks
    Reddy
    Edited by: Surendra Reddy on Nov 21, 2008 1:57 PM

  • Data Loading Error for cube 0TCT_C22

    Dear Colleagues,
    I am working on BI 7.0 / SP09.
    I am loading technical content cube 0TCT_C22 from datasource 0TCT_DS22. Till PSA, there is no problem with data load. But from PSA to data target, data load fails. Went to monitor and it shows teh error "Error calling number range object 0TCTPRCSCHN for dimension D2 (  ). Message no: RSAU023".
    I tried to find the SAP notes fro this, but no success. Also checked the Dump and application logs, but nothing is there.
    Please advice ASAP.
    Regards
    PS

    Hi Pank,
    I just solved the very similar issue. Try what I did to see if it works for you.  For each dimension in each Infocube a number range is created. For some weird reason during the activation of the Infocube the number range for the dimension giving troubles was not created. Look for it in TCODE SNRO and you should find a number range per each dimension in the cube but the one giving you error.
    To solve it, (the easiest way I found) just add any characteristic to the problematic dimension. Activate the Infocube. After that, modify again you Infocube and remove the characteristic you just added to leave the dimension how you need it. Activate the Infocube again. By doing that you will force the regeneration of the dimension and with it the number range. You can chek in TCODE SNRO and the number range should be there. Try loading your data again and it should work.
    One thing I don't understand is why that number range sometimes is not created during activation
    Good luck, I hope you can solve it!!!
    Regards,
    Raimundo Alvarez

  • Loading data for Cube Characteristics

    Hi Experts,
    I have basic questions on loading of data for InfoCube characterisctis.
    1.Suppose I have 6 dimensions and total 26 characteristics are in dimensions.Do I need to load master data for 26 characteristis.
    2.I have master data InfoProvider say 0Customer ,it does have navigational attributes and display attributes.Do I need to define Navigational attribute as a Master data Infoprovider and load data for them or any other way.
    Please clarify my doubts which I am facing in my project now.I will awarded for all inputs.
    Thanks,
    Rani
    Edited by: Rani on Aug 24, 2008 4:18 AM

    Hi,
    Actually its not really clear what your doubt is... If you question is whether you can load data to infocube without maintaining master data for the characteristics - the answer is yes. You can do that; just make sure that you do not tick the option of checking master data while loading.

  • Selection Option question in Info Package

    We would like to stop update Master Data if no master data exists for a characteristics. I found there is a selection options in Info Package Update Tab called "Do not update data if no master data exists for a characteristic"
    I added a row in one of the InfoObject which has been used in another InfoObject as an Attribute. I selected this option in the IP and tried to re-load Master Data, and it didn't fail.
    What does this option do?
    Thanks!

    For example:
    InfoObject ITEM and ITMPLN. ITEM is an Attribute in ITMPLN.
    ITEM has
    Item    Description
    001     Test 1
    002     Test 2
    ITMPLN has
    Project No            Item         Description
    A                         001          Test A
    B                         002          Test B
    <b>C                         004          Test C</b>
    After I load the last row to ITMPLN, I would like to see the error message instead of adding <b>004</b> into ITEM InfoObject. Do you know how to do it?
    Thank you!

  • Two info cubes & one info package

    hi guys,
    i am new to sap environment, now learning sap bw.  can someone can help me, how can i execute two infocubes in one info package.  i could able to execute only one infocube...  can we execute two inofcubes at the sametime... can some help me with detail procedure..
    cheers,
    kishore...

    Hi Kishore,
    Go to the Process monitor screen.Under the Header tab,you have datatargets,where your 2 infocubes will be displayed.
    Click on the Cube2 and you will be navigated to the respective cubes.and here go to the requests tab and and click on Montior screen and you will be naviagted to the process monitor.
    or
    In the infopackage,under datatargets tab.Sleect any one cube and will be naviagted to the Manage session.Under requests tab sleect the monitor screen and you will be naviagted to monitor screen of the cube 2.
    No,you cannot monitor both cubes from same session.You can open a new session and have 2 sesssions montoring 2 cubes
    or go to RSMO and have 2 sessions and monitor it
    hope it helps.

  • Table for Cube request

    Hi Experts,
    I would like to know the table in which data load request for cube is stored with records added and transferred and other cube related details. Please help.

    Hi,
    for the request part you can look at the table RSBKREQUEST by filling in the source or target object.
    Different tables for cube are :
    RSDCUBE    Directory of InfoCubes
    RSDCUBET   Texts on InfoCubes 
    RSDCUBEIOBJ    Objects per InfoCube (where-used list) 
    RSDDIME    Directory of Dimensions 
    RSDDIMET   Texts on Dimensions 
    RSDDIMEIOBJ    InfoObjects for each Dimension (Where-Used List) 
    RSDCUBEMULTI    InfoCubes involved in a MultiCube 
    RSDICMULTIIOBJ     MultiProvider: Selection/Identification of InfoObjects 
    RSDICHAPRO     Characteristic Properties Specific to an InfoCube 
    RSDIKYFPRO    Flag Properties Specific to an InfoCube 
    RSDICVALIOBJ    InfoObjects of the Stock Validity Table for the InfoCube 
    thanks,
    arminder

  • Issue withe Info Package Selection for the CRM Datasource

    Hello,
    I have a custom CRM data-source which has the Selection option as CRM-GUID as the Selection option in the RSA3.
    I have replicated the Same Data-source in BI system and Created the Info Package ,but i could not see that GUID Selection in the Info Package.
    To Be Noted:
    I went to RSA6 enabled the selection option( check Box ) , there is no hide option in the datasource , only the Selection option check box is enabled in the RSA6 .
    Replicated again , and activated again , logged out and logged in again . But the Info Package does not show the CRM - GUID selection option.
    I found something not sure this might be the issue:
    1) The Data type is RAW with length 16.
    2) The Datasource in the BI side has SS conversion Routine Blank for this field and the Selection has X.
    But no Selection option in the Info Package.
    Any suggestion and inputs are welcome.
    Thanks in advance.
    Adhvi.

    similar issue is disussed in the below thread...
    Info package Selection were hidden
    Info Package Selection Language key is not diplaying while this is checked
    search for any SAP Note which explains about data type RAW ....

  • Selection field not coming at Infopackage level

    Hi All,
    I am facing a strange problem.There is one field which is marked for selection at the datasource level.In the R/3 side we are getting that field as selection if we go for t-code RSA3.
    But in the BW system when we create an Info-package we do not get the same field under Data selection tab.We have tried to change the data type of that field and replicated the datasource but still it didnt worked.
    Please suggest on this issue as it a very high priority issue for us.
    Thanks in advance.
    Regards,
    Kshitij

    Hi Naveen,
    1) This is not a standard datasource.
    2) In RSA2 that field is marked for selection and it is showing for selection if we go for RSA3.
    3) Could you please elobrate more on what do you mean by 'attribute column'.???
    In R/3 system we have the same field for selection ( this field is related to 'no of days'=zdays[info object name]) but at Info package level in BW system it does not appear for selection.
    If you have time can we call you.Please pass on your number to me.
    Regards,
    Kshitij

  • Adding a field in data selection tab of Info Package

    Hello,
    how can I add a field for selection in the data selection tab of the info-package in BW 3.5.
    Thanks,
    SD

    Hi,
    You need check Selection in RSO2 in ECC then that field is available for Selectgion in InfoPackage.
    Here I'm giving 0CUST_SALES_ATTR DataSource Example for Selection Change, so see the logic and accordingly you can change your DataSource Selections.
    See the properties of that field in RSA2 in ECC and you can also make it for selection, use the following program and see it.
    In ROOSFIELD table give the datasource 0CUST_SALES_ATTR and see , select only Active version Fields.
    For the following fields you can find FIELD = X, it indecates that it is abailable for selections, so in this way you try to do it by using following program and check.
    KUNNR
    SPART
    VKORG
    VTWEG
    REPORT ZBI_ROOSFIELD NO STANDARD PAGE HEADING .
    tables ROOSFIELD.
    Update ROOSFIELD set SELECTION = 'X' where
    OLTPSOURCE = '0CUST_SALES_ATTR' and
    FIELD = 'FAKSD '.
    Also see SAP Note : 1033847
    Re: Field Selection in Datasource 0CUST_SALES_ATTR
    Thanks
    Reddy

  • Info Package load 'Time Lag'

    Hi Experts,
    Is there a table which holds information about time lag of a info package run.
    If yes which field of dat table gives this information ?
    If there is no direct method, is there a indirect method to derive it from any table.
    I badly need to get it from a table, coz I need to document this for lot of info packages, and if I do it manually it takes lot of efforts (going to "details" tab of every info package run and all dat stuff..)
    Points would be awarded for sure.
    Thanks,
    Mihir

    Hi Mihir,
    Check table: RSMONICTAB -- Monitor, Data Targets(Infocube/ODS) Table, request related info and
                       RSMONIPTAB -- InfoPackage for the monitor
    and also you will get load details from statistics.
    More info at: [BW Useful Tables|http://sapbwneelam.blogspot.com/2007/08/bw-useful-tables.html]
    Hope it Helps
    Srini

  • Prob during creation of info package

    When I create an info package by right clicking on the data source, the master data object name is shown and I say save and it is not coming up in the data selection tab of the info package while creating....what could be the error...pl. help
    thanks
    Dora

    Hi Jr,
       The info package is fetching the data and I see the data in the PSA, but further when I am trying to create a DTP, and get the flat file master data into the attributes, it is not fetching it properly. DTP is getting created but, the data is not in the attributes.....also when I see the monitor it shows:
    Prepare for Extraction
    Data Package 1 ( 3 Data Records )
    Extraction DataSource ZDS_TEST : 3 Data Records
    Filter Out New Records with the Same Key : 3 -> 3 Data Records
    RSDS ZDS_TEST ZSS_TEST -> IOBJ ZCUST1 : 3 -> 3 Data Records
    Updating attributes for InfoObject ZCUST1 : 3 -> 0 Data Records
    pl. let me know what the prob. is....
    Thanks
    Dora

  • Initialize Delta Load in Info Package

    Hi,
    I want to create 2 info packages for my load from datasource.
    One with setting " Initialize Delta load with data transfer " in info package for my first load.
    Second info package should be with " Delta Lad " which i am not finding in the second info package i am creating. Can you please tell me how can i get this setting as i am getting only Full or Intialize delta load only.
    Regards
    Syed

    Make sure the following:
    1) DataSource is Delta Enabled
    2) An Init (or an Early Init) has already been done successfully. You should see the entry in RSA7 of the Source ERP
    You should then be able to get the Delta option in the InfoPackage

  • Selections in Info package

    Hi,
    Can any one help me  in  selecting the data through info package where
    Key figure1<>0 <b>AND</b>  key figure <> 0. 
    I.e    I have the extractor which is pulling 50 millions of data and  updating only 1 million.The reason  I have a code in the start routine which says  if  Key figure1 = 0 AND  keyfigure 2 =0  then delete the data.  Instead of pulling 50 million  and deleting the data at start routine .
    I am trying to implement the same logic in info package by which I can select only 1 million through OlAP variable and ABAP routine. 
    Regards
    Sudheer

    Hi,
    is the extractor based on a standard BC extractor or on a generic datasource ? If it's based on a generic datasource then you can probably adn these selection in the view it's based on.
    regards,
    Raymond Baggen
    Uphantis bv

Maybe you are looking for

  • Query of Query help

    I'm using the same table to run the first 2 queries as I need cumulative numbers by different fields. In the third query I want to use the results from the first 2 queries to find an overall result. I can do this is MS Access but can't seem to get it

  • One Itunes library for Ipod and touch

    I have a 5th generation Ipod and plan on upgrading to the Ipod touch. Can I keep my one itunes library for both devices or does each device have to have its own itunes account/library?

  • AP Accrual Report

    Hi Experts, I am just wondering that is there any standard SAP report for the PO Accrual details.  Appreciate your valued suggestions. Thanks, RPC.

  • Case-when-then logic in join condition

    Is it possible to implement case when then logic in join condition? Instead of: INGRP1.COL1 = INGRP2.COL1 (+) something like: case when INGRP1.COL2 IS NULL then INGRP1.COL1 = INGRP2.COL1 (+) else INGRP1.COL3 = INGRP2.COL3 (+) end expression builder f

  • Trapping Error through PL/SQL

    I was wondering if there is a way to trap errors somehow. I am trying a FOR..LOOP and I am looping through one table, through a cursor and inserting into another table. There some records that may not meet the criteria of the table that is being inse