Urgent help needed with reading data from Cube

Hi Gurus,
Can anyone tell me how to read a value from a record in the CUBE with a key (combination of fields).
Please provide if you have any custome Function Module or piece of code.
Any ideas are highly appreciated.
Thanks,
Regards,
aarthi

Due to the nature of the cube design, that would be difficult, that's why there are API's, FMs, and MDX capabilities - to eliminate the need to navigate the physical structure.  Otherwise you would have to concern yourself with:
- that there are two fact tables E and F that would need to be read.  The Factview could take of this one.
- you would want to be able to read aggregates if they were available.
- the fact table only as DIM IDs or SIDs (for line item dims) to identify the data, not characteristic values.  A Dim ID represents a specific combination of characteristic values.

Similar Messages

  • Urgent: Problem with reading data from cube.

    Hi Gurus,
    I am trying to read the data from the cube. Below is my code. It returns nothing. Could any please help me to solve this.
    TYPES:
      BEGIN OF S_DATA,
        Z_CHAR1    like  /BIC/CTABLE-ZCHAR1,
        Z_CHAR2    like  /BIC/CTABLE-ZCHAR2,
        Z_CHAR3    like /BIC/CTABLE-ZCHAR3,
        Z_FISCPER  like /BIC/CTABLE-0FISCPER,
        0AMOUNT    type  p DECIMALS 2,
      END OF S_DATA.
    data:
           i_s_data  TYPE s_data,
           i_t_data  TYPE STANDARD TABLE OF s_data
                          WITH DEFAULT KEY INITIAL SIZE 10,
           c_data TYPE s_data occurs 0 with header line,
           i_s_sfc   TYPE rsdri_s_sfc,
           i_th_sfc  TYPE rsdri_th_sfc,
           i_s_sfk   TYPE rsdri_s_sfk,
           i_th_sfk  TYPE rsdri_th_sfk,
           i_s_range TYPE rsdri_s_range,
           i_t_range TYPE rsdri_t_range.
    DATA: end_of_data  TYPE rs_bool,
         clear: i_th_sfc.
         g_s_sfc-chanm    = 'Z_CHAR1'.
         g_s_sfc-chaalias = 'Z_CHAR1'.
         g_s_sfc-orderby  = 0.
         INSERT i_s_sfc INTO TABLE i_th_sfc.
         clear: i_s_sfc.
         g_s_sfc-chanm    = 'Z_CHAR2'.
         g_s_sfc-chaalias = 'Z_CHAR2'.
         g_s_sfc-orderby  = 0.
         INSERT i_s_sfc INTO TABLE i_th_sfc.
         clear: i_s_sfc.
         g_s_sfc-chanm    = 'Z_CHAR3'.
         g_s_sfc-chaalias = 'Z_CHAR3'.
         g_s_sfc-orderby  = 0.
         INSERT i_s_sfc INTO TABLE i_th_sfc.
         clear: i_s_sfc.
         g_s_sfc-chanm    = 'Z_FISCPER'.
         g_s_sfc-chaalias = 'Z_FISCPER'.
         g_s_sfc-orderby  = 0.
         INSERT i_s_sfc INTO TABLE i_th_sfc.
         clear: i_s_sfk..
         g_s_sfk-kyfnm    = '0AMOUNT'.
         g_s_sfk-kyfalias = '0AMOUNT'.
         g_s_sfk-aggr     = 'SUM'.
         INSERT i_s_sfk INTO TABLE i_th_sfk.
          clear: i_t_range, i_s_range.
          i_s_range-chanm    = 'Z_FISCPER'.
          i_s_range-sign     = rs_c_range_sign-including.
          i_s_range-compop   = rs_c_range_opt-equal.
          i_s_range-low      = 200601.
          i_s_range-high     = 200606.
          APPEND i_s_range TO i_t_range.
            CALL FUNCTION 'RSDRI_INFOPROV_READ'
              EXPORTING
                i_infoprov             = 'ZC_CUBE'
                i_th_sfc               = i_th_sfc
                i_th_sfk               = i_th_sfk
                i_t_range              = i_t_range
                i_reference_date       = sy-datum
                i_save_in_table        = rs_c_false
                i_save_in_file         = rs_c_false
                i_packagesize          = 20
              IMPORTING
                e_t_data               = i_t_data
                e_end_of_data          = end_of_data
              CHANGING
                c_first_call           = i_first_call
              EXCEPTIONS
                illegal_input          = 1
                illegal_input_sfc      = 2
                illegal_input_sfk      = 3
                illegal_input_range    = 4
                illegal_input_tablesel = 5
                no_authorization       = 6
                ncum_not_supported     = 7
                illegal_download       = 8
                illegal_tablename      = 9
                OTHERS                 = 11.
                append lines of I_t_data to c_data.
    Thanks
    Regards
    aarthi
    [email protected]

    Due to the nature of the cube design, that would be difficult, that's why there are API's, FMs, and MDX capabilities - to eliminate the need to navigate the physical structure.  Otherwise you would have to concern yourself with:
    - that there are two fact tables E and F that would need to be read.  The Factview could take of this one.
    - you would want to be able to read aggregates if they were available.
    - the fact table only as DIM IDs or SIDs (for line item dims) to identify the data, not characteristic values.  A Dim ID represents a specific combination of characteristic values.

  • Help needed with loading data from ODS to cube

    Hi
    I am loading data from an ODS to a cube in QA. The update rules are active and definition seems right. I am getting the following error, in the update rules.
    "Error in the unit conversion. Error 110 occurred"
    Help.
    Thanks.

    Hi Chintai,
    You can see the record number where the error occured in the monitor (RSMO) for this data load > goto the details tab and open up the Processing area (+ sign). Try it out...
    Also about ignoring the error record and uploading the rest, this is done if you have set Error Handling in your InfoPackage (Update tab), but this would have to be done before the load starts, not after the error happens.
    Hope this helps...
    And since you thanked me twice, also please see here:-) https://www.sdn.sap.com/irj/sdn?rid=/webcontent/uuid/7201c12f-0701-0010-f2a6-de5f8ea81a9e [original link is broken]

  • Urgent help needed - writing/ reading to/from file

    hi all..
    can anyone help me with this problem:
    The problem dioscussed in www.javaworld.com forum
    any clues what the problem is??

    hi all...
    i managed to get the gui set up, and the JList is finally loading the data,
    yet, i am having problems with displaying relevant data of each item in the list...
    could you please help??
    // required imports
       import javax.swing.*;
       import java.awt.*;
       import java.awt.event.*;
       import javax.swing.event.*;
       import java.io.*;
       import java.util.*;
    // ViewPanel class: the panel for the view pane. handles its own events.
       public class ViewPanel extends JPanel implements ListSelectionListener
          private JList list;
          private DefaultListModel listModel;
          private JButton deleteButton;
          private TicketStorage data;
       // add pane items
          private JLabel seat, seatData;
          private JLabel name, nameData;
          private JLabel duration, durationData;
          private JLabel price, priceData;
          private JCheckBox waiterService;
       // creating panels
          JPanel p1 = new JPanel();
          JPanel p2 = new JPanel();
          public ViewPanel(TicketStorage data)
          // store data structure reference
             this.data = data;
             TrainTicket[] summary = data.summary();         
             listModel = new DefaultListModel();
             for (int i = 0; i < summary.length; i++)
                listModel.addElement(summary.getSeat());
    list = new JList(listModel);
    list.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
    list.setSelectedIndex(0);
    list.setVisibleRowCount(5);
    JScrollPane listScroller = new JScrollPane(list);
    listScroller.setPreferredSize(new Dimension(100, 150));
    seat = new JLabel("Seat No:");
    seatData = new JLabel();
    name = new JLabel("Name:");
    nameData = new JLabel();
    duration = new JLabel("Duration:");
    durationData = new JLabel();
    price = new JLabel("Price:");
    priceData = new JLabel();
    // create add pane items
    waiterService = new JCheckBox("Waiter Srevice");
    waiterService.setEnabled(false);
    // waiterService.addActionListener(boxListener);
    JButton deleteButton = new JButton("Delete");
    // deleteButton.addActionListener(buttonListener);
    // adding listeners to the components
    //deleteButton.addActionListener(this);
    //waiterService.addActionListener(this);
    list.addListSelectionListener(this);
    // adding the components to their coreesponding panels
    p1.setLayout(new GridLayout(5,1));
    p1.add(seat);
    p1.add(name);
    p1.add(duration);     
    p1.add(price);
    p1.add(waiterService);
    p2.setLayout(new GridLayout(5,1));
    p2.add(seatData);
    p2.add(nameData);
    p2.add(durationData);     
    p2.add(priceData);
    p2.add(deleteButton);
    this.setLayout(new GridLayout(1,3,3,0));
    this.add(listScroller);
    this.add(p1);     
    this.add(p2);
    public void valueChanged(ListSelectionEvent e)
    if (e.getValueIsAdjusting() == true)
    // enable the delete button when an item is selected
    deleteButton.setEnabled(true);
    // retrieve the sellected seat number value
    String itemSellected = listModel.getElementAt(list.getSelectedIndex()).toString();
    // retrieve the ticket with the sellected seat number
    TrainTicket tk = data.retrieve(itemSellected);
    // load the relevant data of a sellected ticket
    seatData.setText(tk.getSeat());
    nameData.setText(tk.getName());
    durationData.setText(Integer.toString(tk.getDuration()));
    priceData.setText(Double.toString(tk.getPrice()));
    /*/ if the selected ticket of type first class
    if(tk instanceof FirstClassTicket)
    if(((FirstClassTicket)tk).getWaiter()==true)
    waiterService.setSelected(true);
    waiterService.setEnabled(true);
    else
    waiterService.setSelected(false);
    waiterService.setEnabled(true);
    else
    waiterService.setSelected(false);
    waiterService.setEnabled(false);
    the application runs, it loads the data available in the linked list,
    yet, on switching from an item to another in the list, it keeps generating errors!!!
    in addition to the fact that it does not display the data!!
    for more info refer to the url in my first post!
    any clues??

  • Help needed in reading data from a Crystal Report

    I am trying to read data values from a saved crystal report. (groovy code snippet below)
    I open a new ReportClientDocument and set the RAS using the inprocConnectionString property.
    Then I get the rowsetController and set defaultNumOfBrowsingRecords, rowsetBatchSize and maxNumOfRecords all to 1000000
    Using the browseFieldValues method after that returns only 100 records. I want to get all.
               ReportClientDocument clientDocSaved;
           def pathout=rc.pathToSavedReports+rr.path;
         //****** BEGIN OPEN SAVED SNAPSHOT ************
         clientDocSaved = new ReportClientDocument();
         clientDocSaved.setReportAppServer(ReportClientDocument.inprocConnectionString);       
            // Open report
         println("Reading file in.")
         clientDocSaved.open(pathout, OpenReportOptions._openAsReadOnly);
           def rowsetController = clientDocSaved.getRowsetController()
         rowsetController.setDefaultNumOfBrowsingRecords(1000000)
         rowsetController.setRowsetBatchSize(1000000)
         rowsetController.setMaxNumOfRecords(1000000)
         //setup metadata
         IRowsetMetaData rowsetMetaData = new RowsetMetaData()
         Fields fields =  clientDocSaved.getDataDefController().getDataDefinition().getResultFields()
         rowsetMetaData.setDataFields(fields)
         def values = rowsetController.browseFieldValues(fields.get(0), 1000000)
         values.each{value->
            println(value.displayText(new Locale("ENGLISH")))
    Before using the browseFieldValues method I was trying to use a rowsetCursor
                //get the rowset cursor to navigate through the results
                RowsetCursor rowsetCursor = clientDoc.getRowsetController().createCursor(null, rowsetMetaData)
                //navigate through the rowset and log the name and value
                rowsetCursor.moveTo(0)
                while(!rowsetCursor.isEOF()){
                     Record currentRecord = rowsetCursor.getCurrentRecord()
                     //println("current record number: " + rowsetCursor.getCurrentRecordNumber())
                     for(int i=0;i<fields.size();i++){
                          //println("Column - "+fields.get(i).getName())
                          if (currentRecord.size()>0){
                              println(currentRecord.getValue(i))
                     rowsetCursor.moveNext()
    the currentRecord was always an empty list and I did not get any data values at all.
    Am I missing something in using these approaches?
    I'm fairly new to using the Java SDK for CR. Any help will be greatly appreciated.
    Thanks

    hi, I am trying this second method to read the values from report. but all the records comming as null. Kindly help me to resolve this issue.

  • Urgent help needed with un-removable junk mail that froze Mail!!

    Urgent help needed with un-removable junk mail that froze Mail?
    I had 7 junk mails come in this morning, 5 went straight to junk and 2 more I junked.
    When I clicked on the Junk folder to empty it, it froze Mail and I can't click on anything, I had to force quit Mail and re-open it. When it re-opens the Junk folder is selected and it is froze, I can't do anything.
    I repaired permissions, it did nothing.
    I re-booted my computer, on opening Mail the In folder was selected, when I selected Junk, again, it locks up Mail and I can't select them to delete them?
    Anyone know how I can delete these Junk mails from my Junk folder without having to open Mail to do it as it would appear this will be the only solution to the problem.

    Hi Nigel
    If you hold the Shift key when opening the mail app, it will start up without any folders selected & no emails showing. Hopefully this will enable you to start Mail ok.
    Then from the Mail menus - choose Mailbox-Erase Junk Mail . The problem mail should now be in the trash. If there's nothing you want to retain from the Trash, you should now choose Mailbox- Erase Deleted Messages....
    If you need to double-check the Trash for anything you might want to retain, then view the Trash folder first, before using Erase Junk Mail & move anything you wish to keep to another folder.
    The shift key starts Mail in a sort of Safe mode.

  • Need to read data from pipe separated file using POJO?

    Hi,
    I need to read data from pipe separated file using POJO.
    There is config.properties file which consists of the
    data mapping.
    Can you help me with sample code or help?
    Regards
    Regards
    Taton
    Edited by: Taton on Mar 7, 2009 4:41 PM

    It's not possible to read from a file without using classes from the core API*. You'll have to get clarification from your instructor as to which classes are and are not allowed.
    [http://java.sun.com/docs/books/tutorial/essential/io/]
    *Unless you write a bunch of JNI code to replicate what the java.io classes are doing.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Need to read data from a text file

    I need to read data from a text file and create my own hash table out of it. I'm not allowed to use the built in Java class, so how would I go implementing my own reading method and hash table class?

    It's not possible to read from a file without using classes from the core API*. You'll have to get clarification from your instructor as to which classes are and are not allowed.
    [http://java.sun.com/docs/books/tutorial/essential/io/]
    *Unless you write a bunch of JNI code to replicate what the java.io classes are doing.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • I need to read data from MQ? any example of OFSML   ?

    I need to read data from MQ so what I should know about this MQ properties ?? such ip,name,....
    I'm new in MQ programming
    and it can be over internet or local network only ?
    I will used the OFSML
    any one know any thing about OFSML or any example ?? Open Financial Services XML interface
    (http://dts.temenos.com/ofsml/)

    It's not possible to read from a file without using classes from the core API*. You'll have to get clarification from your instructor as to which classes are and are not allowed.
    [http://java.sun.com/docs/books/tutorial/essential/io/]
    *Unless you write a bunch of JNI code to replicate what the java.io classes are doing.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Help needed with Reader Integrated Key

    Hi,
    I have develop a plug-in and apply for Reader Integrated Key License. This plug-in have been tested with acrobat and reader professional and it is working.
    I follow the advice from the above website and use RIKLATools.zip to created the pair.
    i have just receive the Reader Integrated Key from Adobe,I tried all method but the key  does not work with the plug-in. What is the fool proof way to integrate my Reader Integrated Key with the plug-in to get a digtally signed plug-in?
    Urgent help needed as we are submitting the plug-in to client.
    many Thanks in advance
    Regards
    Jia hao

    Thank you lrosenth, i will email them

  • Pb with reading data from tubes

    Hello !
    Sometimes when I try to display contents on my web site (Servlet with Websphere), I catch this exception :
    java.io.IOException: There is no process to read data from a tube (It's the translation of "Il n'existe pas de processus pour lire les donn�es dirig�es vers un tube").
    and a wite page will be displayed.
    The exception comes from :
    java.net.SocketOutputStream.socketWrite()
    but I can't understand the cause of this problem.
    If someone knows something about this, please help !
    Thanks

    Hi,
    Create a context node for the screen fields for which you want to enter the values with cardinality 1.1.....
    Now in the layout of your view bind the screen input fields to that context node(attributes) to the value property of the input fields...
    Now in the action of ADD button....
    --> go the wizard and select the read node button and select the node which you have created it generates the auto code for you.....
    for example if the node is contains aone attribute like MATNR
    reading the node from wizard will generate the code as....
    DATA lo_nd_matnr TYPE REF TO if_wd_context_node.
      DATA lo_el_matnr TYPE REF TO if_wd_context_element.
      DATA ls_matnr TYPE wd_this->element_matnr.
      DATA lv_matnr TYPE wd_this->element_matnr-matnr.
    * navigate from <CONTEXT> to <MATNR> via lead selection
      lo_nd_matnr = wd_context->get_child_node( name = wd_this->wdctx_matnr ).
    * @TODO handle non existant child
    * IF lo_nd_matnr IS INITIAL.
    * ENDIF.
    * get element via lead selection
      lo_el_matnr = lo_nd_matnr->get_element( ).
    * @TODO handle not set lead selection
      IF lo_el_matnr IS INITIAL.
      ENDIF.
    * get single attribute
      lo_el_matnr->get_attribute(
        EXPORTING
          name =  `MATNR`
        IMPORTING
          value = lv_matnr ).
    here the variable lv_matnr will contain the entered value......
    now you can use this value for further process.
    Thanks,
    Shailaja Ainala.

  • Problem with reading data from screen and inserting in table

    hi ther,
    im new to abap-webdyn pro. can anyone suggest how to read data from screen and insert into table when press 'ADD' button.
    i done screen gui , table creation but problems with action. what the content of acton add.
    is ther any link that helps me or tut??
    thankx in advance!
    regards

    Hi,
    Create a context node for the screen fields for which you want to enter the values with cardinality 1.1.....
    Now in the layout of your view bind the screen input fields to that context node(attributes) to the value property of the input fields...
    Now in the action of ADD button....
    --> go the wizard and select the read node button and select the node which you have created it generates the auto code for you.....
    for example if the node is contains aone attribute like MATNR
    reading the node from wizard will generate the code as....
    DATA lo_nd_matnr TYPE REF TO if_wd_context_node.
      DATA lo_el_matnr TYPE REF TO if_wd_context_element.
      DATA ls_matnr TYPE wd_this->element_matnr.
      DATA lv_matnr TYPE wd_this->element_matnr-matnr.
    * navigate from <CONTEXT> to <MATNR> via lead selection
      lo_nd_matnr = wd_context->get_child_node( name = wd_this->wdctx_matnr ).
    * @TODO handle non existant child
    * IF lo_nd_matnr IS INITIAL.
    * ENDIF.
    * get element via lead selection
      lo_el_matnr = lo_nd_matnr->get_element( ).
    * @TODO handle not set lead selection
      IF lo_el_matnr IS INITIAL.
      ENDIF.
    * get single attribute
      lo_el_matnr->get_attribute(
        EXPORTING
          name =  `MATNR`
        IMPORTING
          value = lv_matnr ).
    here the variable lv_matnr will contain the entered value......
    now you can use this value for further process.
    Thanks,
    Shailaja Ainala.

  • Problem with downloading data from cube into flatfile

    Hi,
    I am writing a program to download data from cube into flatfile .The program will be run in the background with user has given his selection in a table.the program works fine .The current problem which i am facing is the character length.e.g. Material is 18 ..but in my dynamic internal table it store the value of material with length of 10 character.
    So i am not able to see the output material in correct format.Anybody knows how to change this format.
    thanks in advance
    Yogesh Mali

    Hi Yogesh,
    Theorethically, you can setup the material code length in TX OMSL, which uses the TMCNV table.
    Why don't you change the structure of your internal table changing material fiela length from 10 to 18?
    Best regards,
    Eugene

  • Help needed to insert data from different database

    Hi ,
    I have a requirement where i need to fetch data from different database through database link .Depending on user request , the dblink needs to change and data from respective table from mentioned datbase has to be fetched and populated .Could i use execute immediate for this, would dblink work within execute immediate .If not , could pls let me know any other approach .

    What does "the dblink needs to change" mean?
    Are you trying to dynamically create database links at run-time? Or to point a query at one of a set of pre-established database links at run-time?
    Are you sure that you really need to get the data from the remote database in real time? Could you use materialized views/ Streams/ etc to move the data from the remote databases to the local database? That tends to be far more robust.
    Justin

  • I need to read data from a text file and display it in a datagrid.how can this be done..please help

    hey ppl
    i have a datagrid in my form.i need to read input(fields..sort of a database) from a text file and display its contents in the datagrid.
    how can this  be done.. and also after every few seconds reading event should be re executed.. and that the contents of the datagrid will keep changing as per the changes in the file...
    please help as this is urgent and important.. if possible please provide me with an example code as i am completely new to flex... 
    thanks.....  

    It's not possible to read from a file without using classes from the core API*. You'll have to get clarification from your instructor as to which classes are and are not allowed.
    [http://java.sun.com/docs/books/tutorial/essential/io/]
    *Unless you write a bunch of JNI code to replicate what the java.io classes are doing.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Maybe you are looking for