Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Vendor Code Datatype

Former Member
0 Kudos

Hi

I have done a module mool where we have to key in a vendor and do some operation.

My requirement is, if i give the vendor code, its name should be printed in the name field.

For ex: vendor code : '0000000025' name should be dispalyed as 'Metropol'.

But when i select the vendor code '0000000025', system is accepting that as '25' only. so iam unable to retrive the record..

Can anyone help me out in this..

Cheers

Christina.

1 ACCEPTED SOLUTION

former_member265047
Active Participant
0 Kudos

Hi,

Please use CONVERSION_EXIT_ALPHA_INPUT function module before getting the data from the data base. it will convert vendor no i.e., 25 to 000000025.

then you wont get any issues.

Regards,

Naveen Veshala

5 REPLIES 5

former_member195383
Active Contributor
0 Kudos

u can check the type declaration of the input field...through which you are inputting the vendor code value...It must be of the same type as the field of the table from which you are picking the value..may be because of datatype mismatch its happening...

Or declare that input field as a character variable...that may help u out...

0 Kudos

Hi

I did the same thing,. I have declared that a sthe same type of that table.

Also I tried by declaring as Char datatype also..

But it is working out fine..

Is there any other method that you can suggest..

Cheers

Christina

former_member265047
Active Participant
0 Kudos

Hi,

Please use CONVERSION_EXIT_ALPHA_INPUT function module before getting the data from the data base. it will convert vendor no i.e., 25 to 000000025.

then you wont get any issues.

Regards,

Naveen Veshala

Former Member
0 Kudos

Hi,

User vendor code input data declaraction type shound be use 'LIFNR'.

OR

Use CONVERSION_EXIT_ALPHA_INPUT function module.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'

EXPORTING

input = input " 00025

IMPORTING

output = lv_lifnr. "25

Reward if useful...

Thanks,

Durai.V

Former Member
0 Kudos

hi lavanya,

i think ur trying display name of the vendor based on vendor (vbeln)

in ur case though it displaying '0000025' , extenal representation is simply 25.

sometimes it takes care of automatic conversion .( external to internal ie apppends requiered zero to length of field).

in ur case its not taking automatic conversion

so u have to convesion exit

go to se 11 -> vbak -> doulble clck on deta element of vbeln ->domain-> definition tabe

u find Convers. Routine

use that.

Reward if useful.

Raju Mummidi.