View Only
  • 1.  Query T-codeZD51

    Posted 04-12-2024 09:25
      |   view attached

    I am trying to write a query using T-code ZD51. When I enter it manually, I receive results from the t-code. I went in created the query first by recording then by tables and neither one is resulting in any records found. 

    The purpose of the Query is below. 

    Inputs for Query from IDOC Error Report 

    1. Sold to Party-KUNNR: 

    1. Payer/ Headquarter Number-KUNNR: 

    1. Customer Material Number-KDMAT 


    Outputs from Query from ZKNMT Table accessed by ZD51 T-Code 

    1. SW Material Number-MATNR 

    1. CMIR Key-ZZCMIR_KEY:  

    1. Created At-CRTIM 

    1. Created By-CRNAM 

    1. Time Changed-AETIM 

    1. Name of Person who changed the object-AENAM 

    carlos Carlos.Velez


  • 2.  RE: Query T-codeZD51

    Posted 04-12-2024 20:08

    Hi Carlos

    If you are getting results manually, you might check padding on the criteria - does it need to be zero padded or not and the length.

    Best Regards,


    Sigrid Kok
    Precisely Software Inc.

  • 3.  RE: Query T-codeZD51

    Posted 04-15-2024 08:57

    I have tried the no padding and padding both option produce zero results. 

    Carlos Velez

  • 4.  RE: Query T-codeZD51

    Posted 25 days ago

    Hi Carlos,

    I recommend going to the Criteria tab and doing a preview run without any filters to see the format of the data coming from SAP. The preview run will only show the first 100 records. I'm not able to replicate your script since it's a custom table, but I used the KNMT table which has some of the fields you're using. Seeing the format of the output should help you figure out how to format the inputs. 

    You might also find a conversion exit helpful, but it will degrade performance. You can find this option in the workspace tab:


    Maria Ebner
    Precisely Software Inc.