MDM API to read the Record Key Mapping table

Hi,
Does anybody know what class/method I can use to read the Record Key Mapping table?
For the Business Partner table the Key Mapping table has this columns:
<u>Default / MDM Partner ID / Remote System / Key</u>
I have everything but the Key. How can I read it?
Thanks in advance,
Diego.

GetKey Mapping is one of the available Web Services as of SP4.
Else you could use the Java API to get the Key Mapping.
<b>CatalogData class</b> has the following method
<b>GetKeyMapping</b>
public java.lang.String[][] GetKeyMapping(java.lang.String agency,
                                          java.lang.String table,
                                          int[] recordIDs,
                                          boolean isDefaultKeyOnly)
                                   throws StringExceptionRetrieves the key mapping for each record.
Parameters:
agency - the agency name.
table - the table name.
recordIDs - the list of records.
isDefaultKeyOnly - True to retrieve only the default value, False to all key values.
Returns: the key values for each record.

Similar Messages

  • Java API to read the Encrypted Values from Windows Registry settings

    Is there any Java API to read the Encrypted Values from Windows Registry settings ?
    My Java Application invokes a 3rd party Tool that writes the key/value to windows registry settings under : “HKLM\Software\<3rdparty>\dataValue”.
    This entry is in BINARY and encrypted with 3DES, using crypto API from Microsoft.
    3rd party software to encrypt the data stored in registry it
    either uses C++ code: and uses the call “CryptProtectData” and “CryptUnProtectData” or
    If it is a .NET (C#) it uses the call “Protect” or “UnProtect” from class “ProtectData” of WinCrypt.h from the library “Crypt32.lib.
    Note: The data is encrypted using auto-generated machinekey and there is no public key shared to decrypt the Encrypted data.
    Since the data is encrypted using auto-generated machinekey the same can be decrypted from a .Net / C++ application using CryptUnprotectData or UnProtect() API of WinCrypt.h from the library “Crypt32.lib.
    To know more about Auto-Generated MachineKey in Windows refer the links below
    http://aspnetresources.com/tools/machineKey
    http://msdn.microsoft.com/en-us/library/ms998288.aspx
    I need to find a way in Java to find the equivalent API to decrypt (CryptUnprotectData) and Microsoft will automatically use the correct key.
    But i couldn't find any informato related to Java APIs to enrypt or decrypt data using auto-generated machinekey.
    Is there a way to read the encrypted data from Windows regsitry settings that is encrypted using the Auto-Generated Machine Key ?
    Kindly let me know if Java provides any such API or mechanism for this.

    If the symmetric key is "auto-generated" and is not being stored anywhere on the machine, it implies that the key is being regenerated based on known values on the machine. This is the same principle in generating 3DES keys using PBE (password-based-encryption). I would review the documentation on the C# side, figure out the algorithm or "seed" values being used by the algorithm, and then attempt to use the JCE to derive the 3DES key using PBE; you will need to provide the known values as parameters to the PBE key-generation function in JCE. Once derived, it can be used to decrypt the ciphertext from the Regiistry in exactly the same way as the CAPI/CNG framework.
    An alternate way for Java to use this key, is to write a JNI library that will call the native Windows code to do the decryption; then the Java program does not need to know details about the key.
    That said, there is a risk that if your code can derive the key based on known seeds, then so can an attacker. I don't know what your applicatiion is doing, but if this is anything related to compliance for some data-security regulation like PCI-DSS, then you will fail the audit (for being unable to prove you have adequate controls on the symmetric key) if a knowledgable QSA probes this design.
    Arshad Noor
    StrongAuth, Inc.

  • How to read the records from VO

    hi
    How to read the records from VO and after reading the records the selected records has to be save to DB thru other VO
    help me out

    hi,
    its a custom one i am creating
    Select C.Name, A.Primary_Flag, , B.Comments, B.ATTRIBUTE_CATEGORY, B.ATTRIBUTE1, B.ATTRIBUTE2
    FROM XXVOC_CSD_PRIME_DIAG_CODES_B A, XXVOC_CSD_PRIME_DIAG_CODES_TL B, CSD_DIAGNOSTIC_CODES_TL C, CSD_RO_DIAGNOSTIC_CODES D
    Where A. RO_DIAGNOSTIC_CODE_ID = D. RO_DIAGNOSTIC_CODE_ID
    AND A. RO_DIAGNOSTIC_CODE_ID = B. RO_DIAGNOSTIC_CODE_ID
    AND C.DIAGNOSTIC_CODE = D.DIAGNOSTIC_CODE
    AND A.REPAIR_LINE_ID = :1
    UNION
    SELECT C.NAME, ‘’, ‘’, ‘’,’’,’’
    FROM CSD_DIAGNOSTIC_CODES_TL C, CSD_RO_DIAGNOSTIC_CODES D
    WHERE C.DIAGNOSTIC_CODE = D.DIAGNOSTIC_CODE
    AND D.REPAIR_LINE_ID = :1
    from above query i have to select attributes and set it in the EO based VO
    Edited by: Naveenapps on Feb 22, 2009 10:36 PM

  • I can't reactivate windows as i can't read the product key on the bottom of my dv6-1350us

    i can't reactivate windows as i can't read the product key on the bottom of my povilion dv6-1350us

    You can check for problems with the sessionstore.js and sessionstore.bak files in the Firefox profile folder that store session data.
    Delete the sessionstore.js file and possible sessionstore-##.js files with a number and sessionstore.bak in the Firefox profile folder.
    *Help > Troubleshooting Information > Profile Directory: Show Folder (Linux: Open Directory; Mac: Show in Finder)
    *http://kb.mozillazine.org/Profile_folder_-_Firefox
    *http://kb.mozillazine.org/Multiple_profile_files_created
    Deleting sessionstore.js will cause App Tabs and Tab Groups and open and closed (undo) tabs to get lost and you will have to recreate them (make a note or bookmark them if possible).

  • Regarding how to delete the record in internal table

    Hi experts ,
    how to delete the record in intarnal table after validating the data,
    if record contains invalid fields?
    i am giving my code see this and give me the answer?
    loop at it_data into wa_data .
    Validate  Cost Center
        READ TABLE it_kostl INTO wa_kostl WITH KEY kostl = wa_data-kostl BINARY SEARCH.
        IF sy-subrc NE 0.
          PERFORM update_error_log USING wa_data
                                         text-004.
        ENDIF.
    Validate source file material ( material number )
    loop at it_mara into wa_mara .
      read table it_ausp into wa_ausp with key atwrt = wa_data-i_matnr .
               if sy-subrc NE 0 .
       PERFORM update_error_log USING wa_data
                                           text-002.
    delete it_data-objek .
         else.
      read table it_mara into wa_mara with key  matnr = wa_ausp-objek .
           if sy-subrc EQ 0 .
           wa_data-objek = wa_mara-matnr.
           wa_data-matkl = wa_mara-matkl.
         ENDIF.
         Modify it_data from wa_data  .
      endif.
    *endloop.
    Validate unit of measure (unit)
        READ TABLE it_t006 INTO wa_t006 WITH KEY msehi = wa_data-unit .
        IF sy-subrc NE 0.
          PERFORM update_error_log USING wa_data
                                         text-003.
        endif.
    Validate delivery location ( storage location )
        READ TABLE it_lgort INTO wa_lgort WITH KEY del_loc = wa_data-del_loc.
        IF sy-subrc NE 0.
          PERFORM update_error_log USING wa_data
                                         text-001.
             if wa_data-flag ='x' .
          delete it_data from  wa_data .
        endif.
        ENDIF.
    endloop.

    Hi Naren,
    First get the index number of the IT_data table and store it in one variable whose declaration like this.
    data: tabix type sy-tabix.
    while reading the internal table it_data set the tabix variable.
    tabix = sy-tabix.
    Instead of  the above use below one.
    Delete it_data-objek
    Use the Below statement it will delete  the row from the internal table.
    Delete it_data-objek index tabix
    Thanks,
    Chidanand

  • Sending email after deleting the records in a table

    Hi
    I am deleting the records in a table. After deleting the records,
    i want to send an email to another person. I am planning to follow this steps.
    1. Create a trigger on the table(AFTER DELETE ON table FOR EACH ROW)
    to copy the deleted records to temporary table.
    2. Read the temporary table and send an email.
    Is there any other way we can do with out creating temporary table ?.
    Govind

    I don't know what you plan to use to send the mail but here's a solution that would work.
    -- Create a send mail procedure
    create or replace procedure send_mail (
    sender      IN VARCHAR2,
    recipient   IN VARCHAR2,
    message     IN VARCHAR2)
    IS
      mailhost VARCHAR2(30) := 'localhost';
      mail_conn utl_smtp.connection;
    BEGIN
    mail_conn :=  utl_smtp.open_connection(mailhost, 25);
      utl_smtp.helo(mail_conn, mailhost);
      utl_smtp.mail(mail_conn, sender);
      utl_smtp.rcpt(mail_conn, recipient);
      utl_smtp.data(mail_conn, message);
      utl_smtp.quit(mail_conn);
    END;
    /-- Create the trigger to email deleted rows
    create or replace trigger email_del_rows
    after delete on <table>
    for each row
    declare
    msg varchar2(2000);
    begin
    msg := 'COL1  COL2  COMPANY NAME  DATE'||chr(10);
    msg := msg||:old.col1||'    '||:old.col2||'    '||:old.company_name||'       '||:old_date|| chr(10);
    msg := msg||'END OF FILE';
    send_mail('SENDER','[email protected]',msg);
    end;
    /You can make it look pretty but you get the basic idea.

  • How to read the date of ZL table in schema

    Dear all,
    I want to read the record of the ZL table,and I wanted to read the date of every record in ZL table, and then choose which wage type should be used.
                                                                                    Thank you.

    Hi Simon,
    You need to write a custom function.
    Please refer to the following wiki of mine:
    http://wiki.sdn.sap.com/wiki/display/ERPHCM/CreateaCustomPayrollFunctionUpdatingZL+Table
    Regards,
    Dilek

  • Function module or BAPI that is used to update the records in RBKP table.

    Hello All,
    Can anybody please give me the name of any Function module or BAPI that is used to update the records in RBKP table.
    Please help me
      I need to change the fiscal year in RBKP table
    Thanks in Advance,
    Regards,
    LIJO

    Hi,
    You can use the BAPIs,
    BAPI_ACC_INVOICE_RECEIPT_CHECK Accounting: Check Invoice Receipt (OAG: LOAD PAYABLE)
    BAPI_ACC_INVOICE_RECEIPT_POST  Accounting: Post Invoice Receipt (OAG: LOAD PAYABLE)
    Hope this helps.
    Regards,
    Renjith Michael.

  • Stay on the edit page once saved and see the record as a table

    I like to click on the edit of an interactive report to go to the edit page.
    Once in the edit page, I like to see not only the form to edit the record but also
    the record as a table to see what the record looks like once the save button is clicked below the edit form.
    Thanks.

    Look at the page branches. There will be one or more which goes to the first page. Change it to go to the current page instead of the first page.

  • Triggers to insert the record in a table

    I have two table 1. Holiday 2. Attendance.
    When I insert the record    in holiday table for his
     advance holiday   with empid, the same time I want to insert it attendance table
     automatically for the same date using a trigger
    Insert into attendance (empid,date,holiday) values (20078,07/10/2014,1). If holiday column value 1 represent holiday marked,
     0 represent  holiday not marked. The same thing can happen vice versa
    If employee mark his current attendance as  holiday through attendance,
     it should   be  inserted into holiday table 
    automatically using triggers.
    Insert into  Holiday (empid,date,holiday) values (20078,06/08/2014,1). If holiday column value 1 represent holiday marked,
     0 represent  holiday not marked. The same thing can happen vice versa
    Please I am looking for your help , how I can make it using triggers 
    to insert both table  in two different ways of options.
    Regards
    Pol
    polachan

    Hi polachan,
    According to your description, if you want to synchronize the data between the holiday table and the attendance table while inserting records into holiday table, you need to create a trigger on the holiday table, please try the following syntax.
    use <databasename>
    go
    create trigger Tr_holiday
    on holiday
    for insert
    as
    declare @empid varchar(20),
    @date datetime,
    @holiday int
    select @empid = empid, @date=date, @holiday=holiday from inserted
    declare @qty int
    select @qty =count(*) from attendance where empid=@empid and date=@date and holiday=@holiday
    if @qty<1
    begin
    insert into attendance
    select i.empid,
    i.date,
    i.holiday
    from inserted i
    end
    Meanwhile, if you want to insert the record into the holiday table when holiday is updated to 1 in the attendance table, you need to create another trigger on the attendance table, please try the following syntax.
    use <databasename>
    go
    create trigger Tr_attendance
    on attendance
    for update
    as
    declare @holiday int
    if update (holiday)
    begin
    select @holiday=holiday from inserted
    if @holiday=1
    begin
    insert into dbo.holiday
    select empid,
    date,
    holiday
    from inserted
    end
    end
    For more details about creating triggers in SQL Server, please review this article:
    CREATE TRIGGER (Transact-SQL).
    Thanks,
    Lydia Zhang

  • Error when reading the DDIC-data for table

    Hi Tobias
    We upgraded from DMIS 2011 SP04 to SP07. We are in development system.
    To test initial load, we stopped replication for an existing table and then started replication for the same table.
    Mass transfer id connects ECC system to BW on HANA system.
    Replication errored with the following message:
    Error when reading the ddic-data for table MARD (RFC destination DWACLNT010).
    Looking for your guidance.
    Kind Regards
    Kamaljit Vilkhoo

    Was able to solve using oss note 1972533.

  • SAP MDM 7.1 Vendor Number and key mapping

    We are importing data for vendors whcih DO NOT have any VendorNumber now. (they have some the VendorNumber but not one which can be used in the field Vendor Number.)
    We have to generate the VendorNumber during oar - better - after the import.
    There is not problem creating is after the import with a simple assigmment statemen which contains some rules.
    So far so good.
    The pitfall in creating the number AFTER the import is that NO remote keys are generated.
    Any idea how to create these keys AFTER or DURING import IF hte venoder number is assigned during or after import?

    Hi Lutz-Peter,
    Any idea how to create these keys AFTER or DURING import IF the venoder number is assigned during or after import?
    During Import, if you have local keys for each of these remote system, you can maintain it using Remote key concept.
    But you must have one Matching field(Global ID) for this. Since you are creating Vendor key centrally in MDM using MDM Data Manager. Are you exporting data to different remote systems after creating Vendor number centrally in MDM(which can acts as Global ID) If yes then after data created into Remote systems, you can bring Local ID of remote system with this Global ID during import. 1stly, for this your main table property Key Mapping = yes should be enabled in MDM console.
    So during import you should open MDM Import Manager by selecting required Remote system, you will get one more field in target Remote Key, map this target field with with source Local ID field along with other fields like Global ID etc. So in this you will have your Remote Key for Remote systems.
    However Remote Keys depends on how are you creating Local ID(remote Keys) for remote systems, i mean in Remote systems itself or through MDM Syndicator using Remote system Key Generation concept.
    Regards,
    Mandeep Saini

  • Iterate through all the records in a table using Java API

    Hi All,
    What is the easiest way to iterate through all the records in a given table using Java API? I cannot find any methods that will return all records in a table and the only way I can use is to perform a free form search with a condition that is always true. The code works but is pretty ugly. Is there an alternative to this approach?
    Thanks!
    Kenny

    Hi Kenny,
    You can construct a new Search object with your table's code name, a new ResultSetDefinition object for your table and just execute this search using the GetResultSet method of CatalogData.
    Please look at the following code:
    Search search = new Search(<code name of your table>);
    ResultSetDefinition rsd = new ResultSetDefinition(<code name of your table>);
    rsd.AddField<code name of a field>);
    rsd.AddField(<code name of a field>);
    String sortField = <code name of your sort field>;
    boolean sortAscending = true;
    int page = 0; //page number
    A2iResultSet rs = <your CatalogData object>.GetResultSet(search, rsd, sortField, sortAscending, page);
    for (int i = 0; i < rs.GetRecordCount(); i++)
        Value fieldValue = rs.GetValueAt(i, <code name of a field>);
    Hope this helps,
    Nir
    PS - I really recommend you to start using the new API, as it is much more efficient and straight-forward.

  • How to read the attribute in mapping..

    Hi,
    My source XML looks like this
    <GLDEBITACCT>
                <VALUE>0545-K-2006605-5500001</VALUE>
                <GLCOMP glorder="0">0545</GLCOMP>
                <GLCOMP glorder="1">K</GLCOMP>
                <GLCOMP glorder="2">2006605</GLCOMP>
                <GLCOMP glorder="3">5500001</GLCOMP>
      </GLDEBITACCT>
    Where glorder is the attribute of GLCOMP. Now I have requirement to read the attribute ( atleast 2 of them)
    I have to map to target field checking the value in glorder="1
    For e.g. with above XML, if the value in glorder="1 is K than map value from glorder="2 (2006605) to Target 1.
    IF the glorder="1 is P map the value in glorder="2 to Target 2 and goes on for another one
    How can i acheive this mapping. When I tried putting the value of glorder, i am not getting anything.
    Regards,

    Hi,
    You can use below UDF. Please make sure to select context parameter while creating UDF. There will be 3 input arguments for this function:
    1. GLCOMP (a)
    2 @glorder   (b)
    3 Constant   (c)  --depending upon the target node
    Also conext of attribute @glorder should be same as that of GLCOMP.
    //write your code here
    for(int i=0;i<a.length;i++)
        if(b<i>.equals("1")&&c[0].equals(a<i>))
        for(int j=0;j<a.length;j++)
              if(b[j].equals("2"))
         result.addValue(a[j].toString());
                            break;
    For target node target1 use K as 3rd argument, for target node target2 use P and so on.
    Let me know how it works.
    Regards,
    Anirudh.

  • Reading the record and displaying when u select it using checkbox

    hi,
           how to read the particilar record and display it in a popup screen when u select it using checkbox and then press 'DISP' button in alv(normal alv not with oops concepts).
    like i select a row which is checked (checkbox) it and i have to read that particular record and display (value of keyfield say vbeln) details in a popup screen.

    hi,
    go through the faloowing code.
    this for normal popup.
    *& Report  ZGS_ALV_POPUP_2_SELECT
    REPORT  ZGS_ALV_POPUP_2_SELECT.
    TYPE-POOLS: slis.
    PARAMETERS: p_title TYPE sy-title default 'Sales Document:item data'.
    DATA: itab TYPE vbap OCCURS 0 WITH HEADER LINE,
          selfield TYPE slis_selfield.
    START-OF-SELECTION.
      SELECT *
        FROM vbap
        INTO TABLE itab
        UP TO 20 ROWS.
      CALL FUNCTION 'REUSE_ALV_POPUP_TO_SELECT'
           EXPORTING
                i_title                 = p_title
    *           I_SELECTION             = 'X'
               I_ZEBRA                 = 'X '
    *           I_SCREEN_START_COLUMN   = 0
    *           I_SCREEN_START_LINE     = 0
    *           I_SCREEN_END_COLUMN     = 0
    *           I_SCREEN_END_LINE       = 0
    *           I_CHECKBOX_FIELDNAME    =
    *           I_LINEMARK_FIELDNAME    =
    *           I_SCROLL_TO_SEL_LINE    = 'X'
                i_tabname               = 'ITAB'
                i_structure_name        = 'VBAP'
    *           IT_FIELDCAT             =
    *           IT_EXCLUDING            =
    *           I_CALLBACK_PROGRAM      =
    *           I_CALLBACK_USER_COMMAND =
    *            is_private              =
         IMPORTING
                es_selfield             = selfield
    *            e_exit                  =
           TABLES
                t_outtab                = itab
           EXCEPTIONS
                program_error           = 1
                OTHERS                  = 2.
      IF sy-subrc <> 0.
        MESSAGE i000(8I) WITH sy-subrc.
      ENDIF.
      WRITE:
             /  'Table Index : ', 20 selfield-tabindex,
            /  'Table Name  : ', 15 selfield-tabname,
            /  'Field Name  : ', 15 selfield-fieldname,
            /  'Table-Field : ', 15 selfield-sel_tab_field,
            /  'Field Value : ', 15 selfield-value.
    the falowing code is for how to put checkbox and how to display the selected recods.you combine both codes.
    *& Report  ZRP_SALES
    REPORT  ZRP_SALES NO STANDARD PAGE HEADING.
    DATA: TEMP_DATE_STR TYPE STRING.
    *DATA: TEMP_NETP LIKE VBAK-NETWR.
    DATA: TEMP_NETWR(10).
    *DATA: TEMP_VBELN LIKE VBAK-VBELN.
    DATA: CHECK TYPE C VALUE ' '.
    *DATA: WA_VBELN LIKE VBAK-VBELN.
    DATA: TEMP_DATE LIKE VBAK-ERDAT.
    *DATA: TEMP_NETP_STR TYPE STRING.
    DATA:FNAM(20), FVAL(20).
    TYPES: BEGIN OF MY_VBAK,
           VTWEG TYPE VTWEG,
           VKORG TYPE VKORG,
           SPART TYPE SPART,
           NETWR TYPE NETWR_AK,
           VBELN TYPE VBELN_VA,
           ERDAT TYPE ERDAT,
           END OF MY_VBAK.
    DATA: IT_VBAK TYPE MY_VBAK OCCURS 0 WITH HEADER LINE.
    DATA: WA_VBAK TYPE MY_VBAK.
    DATA: V_VBELN TYPE VBELN,
          V_ERDAT TYPE ERDAT.
    SELECT-OPTIONS:S_VBELN FOR V_VBELN,
                   S_ERDAT FOR V_ERDAT.
    AT SELECTION-SCREEN.
    *Check for Sales Order number to be non-initial.
      IF  S_VBELN IS INITIAL.
    *Checking for Date to be non-nitial.
        IF  S_ERDAT IS INITIAL.
          MESSAGE E003(ZRP_MSG). " Please enter either SO number or Date.
        ELSE.
    *Validating the right low values for Date select option
          SELECT SINGLE ERDAT
                 FROM VBAK INTO TEMP_DATE
                 WHERE VBELN EQ S_VBELN-LOW OR ERDAT EQ S_ERDAT-LOW.
          IF SY-SUBRC NE 0.
            MESSAGE E004(ZRP_MSG).
          ENDIF.
    *Validating the right high values for Date select option
          SELECT SINGLE ERDAT
                  FROM VBAK INTO TEMP_DATE
                  WHERE ERDAT EQ S_ERDAT-HIGH OR VBELN EQ S_VBELN-HIGH.
          IF SY-SUBRC NE 0.
            MESSAGE E005(ZRP_MSG).
          ENDIF.
        ENDIF.
      ELSE.
    *Checking for Date to be non-nitial.
        IF  S_ERDAT IS NOT INITIAL.
          MESSAGE E003(ZRP_MSG). " Please enter either SO number or Date.
        ENDIF.
    *Validating the right low values
        SELECT SINGLE VBELN
               FROM VBAK INTO S_VBELN
               WHERE VBELN EQ S_VBELN-LOW.
        IF SY-SUBRC NE 0.
          MESSAGE E001(ZRP_MSG).
        ENDIF.
    *Validating the right high values
        IF S_VBELN-HIGH IS NOT INITIAL.
          SELECT SINGLE VBELN
                  FROM VBAK INTO S_VBELN
                  WHERE VBELN EQ S_VBELN-HIGH.
          IF SY-SUBRC NE 0.
            MESSAGE E002(ZRP_MSG).
          ENDIF.
        ENDIF.
      ENDIF.
    START-OF-SELECTION.
    *First Screen.
      SET PF-STATUS 'DISP'.
      IF S_VBELN IS NOT INITIAL.
        SELECT   VTWEG VKORG SPART NETWR VBELN ERDAT
               FROM VBAK
               INTO TABLE IT_VBAK
               WHERE VBELN IN S_VBELN.
      ENDIF.
      IF S_ERDAT IS NOT INITIAL.
        SELECT  VTWEG VKORG SPART NETWR VBELN ERDAT
               FROM VBAK
               INTO TABLE IT_VBAK
               WHERE ERDAT IN S_ERDAT.
      ENDIF.
      SORT IT_VBAK BY VKORG VTWEG SPART.
    END-OF-SELECTION.
      LOOP AT IT_VBAK.
        MOVE IT_VBAK-NETWR TO TEMP_NETWR.
        MOVE IT_VBAK-ERDAT TO TEMP_DATE.
        WRITE:/6 CHECK AS CHECKBOX.
        FORMAT COLOR 1.
        WRITE: IT_VBAK-VBELN UNDER 'SALES ORDER NO.' .
        WRITE: IT_VBAK-ERDAT UNDER 'DATE'.
        FORMAT COLOR OFF.
        FORMAT COLOR 2.
        WRITE: TEMP_NETWR UNDER 'NET PRICE'.
        FORMAT COLOR OFF."TEMP_NETWR,
        FORMAT COLOR 3.
        WRITE:IT_VBAK-VKORG UNDER 'SALES ORG',
              IT_VBAK-VTWEG UNDER 'DIST CHANNEL',
              IT_VBAK-SPART UNDER 'DIVISION'.
        FORMAT COLOR OFF.
        SKIP 1.
    *FOR SUBTOTALS
        AT END OF SPART.
          SUM.
          FORMAT COLOR 5.
          WRITE:/6 'SUB TOTOAL OF NET PRICE IS :  '.
          WRITE: 32 IT_VBAK-NETWR CURRENCY 'INR'.
          FORMAT COLOR OFF.
          SKIP 2.
        ENDAT.
    *FOR GRAND TOTALS
        AT LAST.
          SUM.
          FORMAT COLOR 6.
          WRITE:/6 'GRAND TOTOAL OF NET PRICE IS :  ',
          32 IT_VBAK-NETWR CURRENCY 'INR'.
          FORMAT COLOR 6.
        ENDAT.
      ENDLOOP.
    TOP-OF-PAGE.
      FORMAT COLOR  6.
      WRITE:/8    'SALES ORDER NO.',
           27   'DATE',
           42   'NET PRICE',
           57   'SALES ORG',
           70   'DIST CHANNEL',
           87   'DIVISION'.
      FORMAT COLOR OFF.
      SKIP 1.
    *WHEN SALES ORDER IS SELECTED
    AT LINE-SELECTION.
      CASE :SY-LSIND.
        WHEN '2'.
          GET CURSOR FIELD FNAM VALUE FVAL.
          IF FNAM <> 'WA_VBAK-VBELN'.
            MESSAGE E006(ZRP_MSG).
          ELSE.
            SET PARAMETER ID 'MAT' FIELD FVAL.
            CALL TRANSACTION 'MM02' AND SKIP FIRST SCREEN.
      ENDIF.
        ENDCASE.
    *WHEN CLICKED ON PUSH BUTTON IN THE APPLICATION BAR
    AT USER-COMMAND.
      CASE:SY-UCOMM.
        WHEN 'DISP'.
          DO.
            CLEAR CHECK.
            CLEAR: WA_VBAK,TEMP_DATE_STR.
            READ LINE SY-INDEX FIELD VALUE CHECK
               IT_VBAK-VTWEG INTO WA_VBAK-VTWEG
    *           IT_VBAK-NETWR INTO TEMP_NETP_STR
               IT_VBAK-VBELN INTO WA_VBAK-VBELN
               IT_VBAK-ERDAT INTO TEMP_DATE_STR
               IT_VBAK-VKORG INTO WA_VBAK-VKORG
               IT_VBAK-SPART INTO WA_VBAK-SPART.
            IF SY-SUBRC <> 0.
              EXIT.
            ELSEIF CHECK = 'X'.
              FORMAT COLOR 1.
              WRITE: 8 WA_VBAK-VBELN HOTSPOT. "UNDER 'SALES ORDER NO'
              WRITE: 25 TEMP_DATE_STR." UNDER 'DATE'.
              FORMAT COLOR OFF.
    *       FORMAT COLOR 2.
    *                   WRITE: 44 TEMP_NETP_STR." UNDER 'NET PRICE'.
    *       FORMAT COLOR OFF.
              FORMAT COLOR 3.
              WRITE:44 WA_VBAK-VKORG," UNDER 'SALES ORG',
             59 WA_VBAK-VTWEG," UNDER 'DIST CHANNEL',
             72  WA_VBAK-SPART." UNDER 'DIVISION'.
              FORMAT COLOR OFF.
              SKIP 1.
            ENDIF.
          ENDDO.
      ENDCASE.
    TOP-OF-PAGE DURING LINE-SELECTION.
      CASE:SY-LSIND.
        WHEN 1.
          FORMAT COLOR  6.
          WRITE:/8    'SALES ORDER NO.',
                 25   'DATE',
    *       44   'NET PRICE',
                 44   'SALES ORG',
                 58   'DIST CHANNEL',
                 72   'DIVISION'.
          SKIP 1.
          FORMAT COLOR  OFF.
    <b>if helpful reward some points.</b>
    Message was edited by:
            suredarreddy pulimamidi

Maybe you are looking for