How to read Data from ZL table

Can someone give me function module or sample code to read data from ZL table in B2 cluster
Edited by: Saurabh Desai on Jan 13, 2010 9:13 PM

You wanted to extract data, ZL table to precise, from B2 cluster, is that right?
For this the snipped I gave you can be used.
First you need an inlcude with appropriate declarations
INCLUDE rpc2b201.       "-> here b2 structure, ZL table are declared
Now you provide key for the cluster which is what below does
b2-key-pernr = "ee number
b2-key-pabrj = "year to extract data for
b2-key-pabrp = "month to extract data for
b2-key-cltyp = 1.
Now all you need is to extract ZL table form B2 cluster
IMPORT zl   "get ZL table
FROM DATABASE pcl2(b2)  "from cluster B2
ID b2-key.    "for this key
That's it. Now you have correct data in ZL table which you can process further.
Hope now it is clear.
Regards
Marcin

Similar Messages

  • How to Read Data from a table (horizontal axsis) in an existing report

    Hi to all,
    I've a question. I must read the data in a table of an existing report. I develope with BO XI 3.0
    I don't know how to reach the table in my report from SDK.
    this is my code:
    reports = document.getReports();
    rep = reports.getItem(0);     
    the report has the title and a table horizontal axsis.
    I must read the column name(header column) of the table and all rows for retrieving values.
    Thank u in advance for your attention.

    hi ChinMay,
    thank u for your answer.
    I would like to ask u if Ireport refers crystal reports, while i mean to read data from a webi report.
    I've tried in many manners to read this data and i've read the SDK, but i'm unable to reach the table of my report for reading its rows. i'm able to export in XML format, i'm able to get reportelement , block, but in the java's example of SDK its not present how to obtain the reportbody and subsequently the section or directly a table. the example that i've seen show that if u create a new report u can create the reportbody, the section, the table and others. But don't show how to obtain this from an existing report.
    Probably i don't understand very well all the SDK structure and i think that is possbile to read a table(with horizantal axis) in a report without section only passing by the ReportBody.
    I know that u don't have so time to spent for things that are in the SDK, but if it's possible to have ten rows of sample about this question i'll be very happy.
    If it's not possibile, thank u very much for your interesting and disponbility and i'll try again and again and again to solve this.
    Matteo

  • How to read data from cluster table.

    Hi experts.
    CDPOS  --- "Change document items"   ... is a cluster table.
    how to select data from it into an internal table....
    please help..
    i will award points for every help.
    thanks
    saurabh.

    Hi Saurabh,
    Use the foll. statement,
    IMPORT <f1> [TO <g 1>] <f 2> [TO <g 2>] ... FROM MEMORY ID <key>.
    For Eg,
    IMPORT ITAB TO JTAB FROM MEMORY ID 'table'.
    This code reads the internal table ITAB from the cluster "table" into the internal table JTAB.
    Hope it helps.

  • How to Read data from a table which is defined as a field in another table

    Hi
    Iam working with FM: 'CUCB_GET_CONFIGURATION'
    <b>  Import parameter configuration as a table.</b>
      <u>but configuration has another table as a field.</u>
    i want to read the inner table fields.
    how can i read the table which is defined as field in configuration table.
    Please try to give me a solution.
    can i have the declartions too....
    Thanks,
    sri

    Hi jonnakuti,
    1. simple
    2.
    DATA : CONFG      TYPE IBCO2_INSTANCE_TAB2.
    <b>DATA : WA TYPE LINE OF IBCO2_INSTANCE_TAB2.</b>
    3. just copy paste
    4.
    report abc.
    TYPE-POOLS : IBCO2.
    DATA : INSTANCE     TYPE     CUIB_CUOBJ.
    DATA : CONFG      TYPE IBCO2_INSTANCE_TAB2.
    DATA : WA TYPE LINE OF IBCO2_INSTANCE_TAB2.
    CALL FUNCTION 'CUCB_GET_CONFIGURATION'
      EXPORTING
        INSTANCE                           = INSTANCE
      IS_BUSINESS_OBJECT                 =
      IV_MOMENT                          =
      IV_WITH_DB_INSTANCE                =
    IMPORTING
      IBASE                              =
       CONFIGURATION                      = CONFG
      EO_CBASE_REF                       =
    EXCEPTIONS
       INVALID_INPUT                      = 1
       INVALID_INSTANCE                   = 2
       INSTANCE_IS_A_CLASSIFICATION       = 3
       OTHERS                             = 4
    read like this
    LOOP AT CONFG INTO WA.
    ENDLOOP.
    regards,
    amit m.

  • How to Read data from a TABLE

    Hi,
    I am implementing a BADI, the interface has a TABLE type parameters (changing). i checked the data in debug mode in this TABLE. how do i read this contents in my BADI code.
    Thanks
    Akila. R

    hi,
    define a table type and use it.
    check this sample code.
    here cjbai_wbselement_table is structure in badi WORKBREAKDOWN_UPDATE.
        data: wa_prps type line of cjbai_wbselement_table,
          wa_prhi type line of cjbai_wbshierarchy_table.
          read table it_wbs_element into wa_prps index 1.
          if wa_prps-stufe = 1 or  wa_prps-stufe = 2 .
             message '1Your not able to create WBS element
            upto  3rd level'  type 'E'.
          endif

  • Reading Data from Internal Table

    Hi,
    Can anyone please tell me how to read data from Internal Tables in the Event Handler without using the Select statement OnInitialization?
    Thanks,
    Gaurav

    Hi Siddhartha,
    Can you tell me the problem in my code. I tried to work on the way you suggested. Though I have not finished with the coding, I just wanted to know whether I am going in the direction or not.
    I have declared the the structure in Type Defination as
    TYPES: BEGIN OF TEST_STRUC,
             BEGDA TYPE BEGDA,
             ENDDA TYPE ENDDA,
           END OF TEST_STRUC.
    TYPES: TEST_TAB_TYPE TYPE TABLE OF TEST_STRUC.
    In the Event Handler, I have added the following code on OnInputProcessing:
    event handler for checking and processing user input and
    for defining navigation
    DATA TEST_INFO LIKE LINE OF TEST_TAB.
    DATA: MYTAB6 TYPE TABLE OF PA0006,
          MYTAB6_WA LIKE LINE OF MYTAB6.
    REFRESH TEST_TAB.
    CLEAR TEST_INFO.
    MYTAB6_WA-BEGDA = REQUEST->GET_FORM_FIELD( STARTDATE ).
    MYTAB6_WA-ENDDA = REQUEST->GET_FORM_FIELD( ENDDATE ).
    IF EVENT->NAME EQ 'button'
       AND EVENT->SERVER_EVENT EQ 'click'.
      LOOP AT MYTAB6 INTO MYTAB6_WA.
        TEST_INFO-BEGDA = MYTAB6_WA-BEGDA.
        TEST_INFO-ENDDA = MYTAB6_WA-ENDDA.
      ENDLOOP.
      APPEND TEST_INFO TO TEST_TAB.
      CLEAR TEST_INFO.
      NAVIGATION->SET_PARAMETER( NAME = 'test_tab'
      VALUE = 'begda' ).
      NAVIGATION->SET_PARAMETER( NAME = 'test_tab'
      VALUE = 'endda' ).
      NAVIGATION->GOTO_PAGE( 'MyBSP2.htm').
    ENDIF.
    P.S. MyBSP2.htm is my next page.
    Thanks,
    Gaurav

  • Read data from cluster tables

    Hi,
      I met a problem.
      How to read data from cluster tables using:
      b2-key-pernr = 20.
      b2-key-pabrj = 2006.
      b2-key-pabrp = 09.
      b2-key-cltyp = '1'.
      import saldo from database pcl2(b2) id b2-key.
    the problem is that the sy-subrc is always 4, could anyone help me?
    thank you very much!

    Hi,
    Import and export to database is used in two programs and not in the same program.
    <b>ZPROGRAM1.</b>
    tables : indx.
    Data : SALDO type i,
           indxkey LIKE indx-srtfd VALUE 'ZAB1'.
      indx-aedat = sy-datum.
      indx-usera = sy-uname.
      indx-pgmid = sy-repid.
    EXPORT SALDO TO DATABASE indx(zc) ID indxkey.
    In another program,
    <b>ZPROGRAM2.</b>
    tables : indx.
    Data : SALDO type i,
           indxkey LIKE indx-srtfd VALUE 'ZAB1'.
      indx-aedat = sy-datum.
      indx-usera = sy-uname.
      indx-pgmid = sy-repid.
      IMPORT SALDO FROM DATABASE indx(zc) ID indxkey.
    Best regards,
    Prashant

  • Read data from ODS table using value mapping

    hi all;
    can anyone help on how to read data from ODS table using value mapping

    Mudit,
    Take a look at this blog,
    <a href="/people/siva.maranani/blog/2005/08/23/lookup146s-in-xi-made-simpler">DB Lookup in Mapping</a>
    Regards,
    Bhavesh

  • How to read data from a CLUSTER STRUCTURE not cluster table.

    Hi,
    how to read data from a CLUSTER STRUCTURE not cluster table.
    regards,
    Usha.

    Hello,
    A structre doesnt contain data.. so u cannot read from it. U need to find out table of that structure and read data from it.
    Regards,
    Mansi.

  • How to read data from an internal table into a real table?

    Hello experts,
    I'm relatively new to ABAP and I'm trying to figure out how to read data from an internal table into a table that I created.  I'm trying to use the RRW3_GET_QUERY_VIEW_DATA function module to read data from a multiprovider.  I'm trying to read data from the e_cell_data and e_axis_data tables into a table that I've already created.  Please see code below.
    TABLES MULTITAB.
    DATA:
      query_name TYPE RSZCOMPID,
      s_cubename TYPE RSINFOPROV,
      t_cell_data TYPE RRWS_T_CELL,
      t_axis_data TYPE RRWS_THX_AXIS_DATA,
      t_axis_info TYPE RRWS_THX_AXIS_INFO,
      wa_t_cell_data like line of t_cell_data,
      wa_t_axis_data like line of t_axis_data,
      w_corp_tab like line of t_cell_data.
    s_cubename = 'CORP_MPO1'.
    query_name = 'Z_corp_test'.
        CALL FUNCTION 'RRW3_GET_QUERY_VIEW_DATA'
           EXPORTING
             i_infoprovider           = s_cubename
             i_query                  = query_name
            i_t_parameter            = query_string_tab
           IMPORTING
             e_cell_data              = t_cell_data
             e_axis_data              = t_axis_data
             e_axis_info              = t_axis_info.
    If anyone has any information to help me, I would greatly appreciate it.  Thanks.

    Hi,
    <li>Once you call the function module RRW3_GET_QUERY_VIEW_DATA, lets say data is available in the corresponding tables e_cell_data e_axis_data which you have mentioned.
    <li>Modify your internal table defined for other purpose, with data from e_cell_data e_axis_data like below.
    LOOP AT t_cell_data INTO wa_t_cell_data.
      "Get the required data from t_cell_data.
      MOVE-CORRESPONDING wa_t_cell_data TO it_ur_tab.
      "Modify your internal table wih data
      MODIFY it_ur_tab TRANSPORTING <field1> <field2> <field3>.
    ENDLOOP.
    LOOP AT t_axis_data INTO wa_t_axis_data.
      "Get the required data from t_cell_data.
      MOVE-CORRESPONDING wa_t_axis_data TO it_ur_tab.
      "Modify your internal table wih data
      MODIFY it_ur_tab TRANSPORTING <field1> <field2> <field3>.
    ENDLOOP.
    Thanks
    Venkat.O

  • How to send data from internal table to the shared folder in ABAP

    Hi experts,
             My requirement is to transfer data from a file to shared folder. i just did reading data from a file to a internal table. Now i want to send this internal table data into a shared folder which is  "
    xxx\y\z....".
    I do not have any idea on how to send data from internal table to the shared folder path.
    can anybody please help me out how to do this?
    Thanks & Regards
    Sireesha.

    Where that folder is located, its on presentation server i.e. desktop or application server.
    If its on presentation server, use FM GUI_UPLOAD.
    If its on application server, then use DATASET functions. Have a look at below link.
    [File Handling in ABAP|http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3ca6358411d1829f0000e829fbfe/frameset.htm]
    I hope it helps.
    Thanks,
    Vibha
    Please mark all the useful answers

  • Reading Data from a Table With an Expert

    Hi all - I'm trying to write an Expert in OWB that would read data from a table and create a new table based on that information. I have the table creation part down, but how can I read data from a table with an Expert? From what I've read, Experts only deal with metadata, and there is no mechanism in Experts to actually read data in the tables. Does OraTcl work in Experts? Has anyone ever came across this problem, and if so, how did you solve it? Thanks in advance for your time! - Don

    Hi Don
    Can also use Java and JDBC from within Tcl, see the routines in this file below, take modify or whatever;
    http://blogs.oracle.com/warehousebuilder/ombora.tcl
    source <dir>\ombora.tcl
    set g_user scott
    set g_upwd zzzzzz
    set g_hostname localhost
    set g_port 1521
    set g_srvname ora111
    oraconnect $g_user $g_upwd $g_hostname:$g_port:$g_srvname
    oraselect "select * from emp" ""
    As well as dumping the results to stdout (you probably want to comment that part out and change any other part you don't like), g_res is a ResultSet object you can use to do whatever.
    Cheers
    David

  • Read data from E$ table and insert into staging table

    Hi all,
    I am a new to ODI. I want your help in understanding how to read data from an "E$" table and insert into a staging table.
    Scenario:
    Two columns in a flat file, employee id and employee name, needs to be loaded into a datastore EMP+. A check constraint is added to allow data with employee names in upper case only to be loaded into the datastore. Check control is set to flow and static. Right click on the datastore, select control and then check. The rows that have violated the check constraint are kept in E$_EMP+ table.
    Problem:
    Issue is that I want to read the data from the E$_EMP+ table and transform the employee name into uppercase and move the corrected data from E$_EMP+ into EMP+. Please advise me on how to automatically handle "soft" exceptions in ODI.
    Thank you

    Hi Himanshu,
    I have tried the approach you suggested already. That works. However, the scenario I described was very basic. Based on the error logged into the E$_EMP table, I will have to design the interface to apply more business logic before the data is actually merged into the target table.
    Before the business logic is applied, I need to read each row from the E$EMP table first and I do not know how to read from E$EMP table.

  • Read data from 2 tables.

    Hello everyone,
    I created a SQL database in phpMyAdmin. It contains 2 tables.
    'Woninginformatie' and 'Makelaars'.
    I use the next SQL query in my PHP file to read from the
    database:
    SELECT DISTINCT * FROM Woninginformatie
    INNER JOIN Makelaars ON Woninginformatie.ID_mk =
    Makelaars.ID_mk
    WHERE Huiscode = $huiscode"
    The query works correct and I get all the fields from both
    tables. Anyway, in Flash I can only read out the information in the
    table 'Woninginformatie'.
    I use these kind of codes to read from the database:
    eigendomssituatie =
    gegevens.childNodes[0].childNodes[24].firstChild.nodeValue;
    How can I also read data from the second table?

    you can't read data from the 2nd table because because you
    have a table issue, php issue or you can read data from the table
    but are having trouble getting those data into flash? are you using
    echo to return data to flash?

  • How to read data from clusters ??

    Hi ,
    Can any one please help me with procedure to read data from any Pcln tables.....other than pcl2.
    with and without using macros..
    I'm planning to read data from Pcl4 from cluster LA .using the macro RP_IMP_C4_LA. i dont know how to pass the key or where to use the key to read data .
    Please please let me know the standard procedure to read data from cluster tables.(i know PCL2).'
    Thanks In Advance !
    Kiran

    Hi Thomas,
    Just out of curiosity. In our system we have a custom table built which stores data in LRAW format.
    The table is updated using IMPORT/EXPORT FROM/TO DATABASE statements (similar to INDX).
    Can we read the PCL* tables in the same way as INDX ?
    BR,
    Suhas

Maybe you are looking for