‎2009 Jun 09 9:01 PM
Hello All,
I have a field in custom table called BELNR with data elemnt type BELNR_D (character 10). Now on selection of a custom report , I have this field as parameter.
Foe example, one of records have data "444005" in BELNR in custom table. But if I put "444005" for BELNR on selection screen, nothing is retrieved from table but if I put 444005*, then only record 444005 is retrieved.
I am not sure why this happening.
Any help..
Regards,
Jainam..
Edited by: Jainam Shah on Jun 9, 2009 10:01 PM
Edited by: Jainam Shah on Jun 9, 2009 10:01 PM
‎2009 Jun 09 9:05 PM
Run the value through FM CONVERSION_EXIT_ALPHA_INPUT before doing the SELECT. This will append the leading zeroes.
Rob
‎2009 Jun 09 9:05 PM
Run the value through FM CONVERSION_EXIT_ALPHA_INPUT before doing the SELECT. This will append the leading zeroes.
Rob
‎2009 Jun 09 9:06 PM
BELNR_D have the domain BELNR that contains a conversion exit. so before fetching the data (ie making the select on your parameter) you need to use fm CONVERSION_EXIT_ALPHA_INPUT convert and then use this value in the select
a®
‎2009 Jun 10 4:26 AM
Hi Jainam,
PARAMETERS : p_belnr type ztable_belnr.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
INPUT = p_belnr "12345
IMPORTING
OUTPUT = p_belnr."000012345
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
EXPORTING
INPUT = p_belnr "000012345
IMPORTING
OUTPUT = p_belnr."12345
Now write the select statement Accordingly..
‎2009 Jun 10 4:58 AM
Hi,
The domain has a conversion exit attached to it. Therefore, before using it you have to use the FM 'CONVERSION_EXIT_ALPHA_INPUT'. This will resolve your problem.
‎2009 Jun 10 6:20 AM
Hi Jainam,
I thought in a diffrent manner.
CONVERSION_EXIT_ALPHA_INPUT and CONVERSION_EXIT_ALPHA_OUTPUT are good as they are mentioned in domain of belnr.
con't we write like this.
PARAMETERS : p_belnr type belnr_d default '123'.
pack p_belnr to p_belnr.
condense p_belnr.
write:/ p_belnr.
Please let me know if I am wrong.
Regards,
Kumar Bandanadham.