Skip to Content
avatar image
Former Member

Select Query issue when fetching Serial Number

Hi Experts,

Recently facing one issue from Select Query.

I have developed the one Z-table, It contains the fields for material,serial No etc then data elements are referred standard only

Table for Both developments and production systems are contains same data based on this table i have done the Z-program, If i execute the report when passing serial no in where condition development is working fine (sy-subrc = 0) but production system reflects

sy-subrc as 4.

I cant guess the reason for this. Kindly anyone help me out to resolve this issue.

Regards,

Thangam Perumal

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

8 Answers

  • Oct 18, 2016 at 05:31 AM

    Any conversion Exit problem.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 18, 2016 at 06:06 AM

    Hi,

    1. firstly,data exist for that selection criteria.

    Regards,

    Pavan.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 18, 2016 at 06:35 AM

    It it working fine from Development not in Production system.

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 18, 2016 at 06:39 AM

    As written check conversion-exit as well in program as in current values stored in database. If you have same program and same data you must get same result, so it's obviously not the case. Check as well SELECT statement as acquisition of data (call of conversion-exit-input during initial load of data?)

    Regards,
    Raymond

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 19, 2016 at 09:29 AM

    Hi Perumal,

    Check whether the serial no's is getting stored with leading zero's in the table.

    Regards,

    Ramesh

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 18, 2016 at 06:46 PM

    hi,

    are you sure that the tables contains the same info?, check in PRD system using SE11, to chek if data exist.

    If it is the same progra, same data in the tables, maybe it is an authority issue, check SU53

    Regards

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 19, 2016 at 05:35 AM

    Hi Miguel,

    Yes am sure, Same data only existing both system and also confirmed with SE11 as well.

    Both Development and production, using SAP_ALL authorization ID only.

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 19, 2016 at 07:08 AM

    Hi,

    Send your Select Statement. Then we can analyses in better way.

    In your ABAP Code place a BREAK-POINT before the Select Statement , Now copy the exact values which you are passing to WHERE Condition. Then follow the below process..

    In WHERE condition to which fields you are passing the values, Pass those values directly using Database Table(SE11) In PRODUCTION.

    Check record are displaying or not. If no data is coming with that input, then confirm there is no data with that INPUT Values. Check for your Input value having any CONVERSION EXIT .. i.e., For Ex: you are passing 30098 which actual type of 10 Char of Numeric Field . some times the database not accepts above 5 char value, so instead of that we need to convert as shown... 0000030098. we are adding 5 zeros in front of that number.

    You can check this scenario by changing the value in debug mode .... place a dynamic break point in you PRD Program and change this value and execute. If it works then you should use CONVERSTION EXIT for that field...

    Confirm yourself with the above testcase.

    Thanks ,

    Vamsi.

    Add comment
    10|10000 characters needed characters exceeded