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: 

External number Range with leading zeros for Handling Units

Former Member
0 Kudos

Hi Experts

My requirement is to use the External number for the Handling Units provided by vendor.That number starts with 2digits"00"+18 for Example:00123456789123456789

I am Using HU_VEKP Object for no range and maintaining

External No Range From 00000000000900000000 to 00000000000999999999.

But When i am giving Number 00000000000900000001 its only taking

900000001.

Kindly suggest me the right way to take leading zeros.

Rewards for answer sure if it works.

rajesh

3 REPLIES 3

Former Member
0 Kudos

Hi Rajesh,

You need to take the number range object of type NUMC so that it can hold leading zeros also.

Or you can use ALPHA cnversion exits to convert the number.

Regards,

Atish

0 Kudos

Hi Atish

The setting for object HU_VEKP u can find on SNRO tcode

in that Standard setting are

Number length domain: NUMC20

Number range transaction:HUEX

Please suggest

RajeshS

Former Member
0 Kudos

Hi!

I have created an exit which enables to validate the external order number which is a combination of material number of 5 digits and serial number uptill 9 digits and both these separated by a space.My problem is that This which I created correct result in DEV as the serial numbers are only numeric but when I transpported it to the QAT it isnt working as the serail numbers theer are alpha numeric.

Kindly let me know what changes I need to do in this following lines so that my error is removed.

Reward points will definelt be awarded.

(I am preety new to ABAP so pls.)

Thanks

Aarav.

data: l_matnr type matnr,

l_sernr type gernr,

l_matnr1 type matnr,

l_sernr1 type gernr.

check syst-dynnr = '0600'.

check i_actvt = '02' "change

or i_actvt = '32'. "save

if i_aufk-auart = 'CENT'.

if i_aufk-aufex is initial.

syst-msgid = 'Z001'.

syst-msgno = '999'.

syst-msgty = 'E'.

syst-msgv1 = 'Enter the External order Number'.

raise e_message.

endif.

l_matnr = i_aufk-aufex(5).

l_sernr = i_aufk-aufex+5(15).

*

*CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

  • EXPORTING

  • INPUT = l_matnr

  • IMPORTING

  • OUTPUT = l_matnr.

*

*

*CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

  • EXPORTING

  • INPUT = l_sernr

  • IMPORTING

  • OUTPUT = l_sernr.

*

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

EXPORTING

INPUT = l_matnr

IMPORTING

OUTPUT = l_matnr1.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

EXPORTING

INPUT = l_sernr

IMPORTING

OUTPUT = l_sernr1.

select count(*) from equi where

matnr = l_matnr1 and

sernr = l_sernr1.

if sy-dbcnt = 0.

syst-msgid = 'Z001'.

syst-msgno = '999'.

syst-msgv1 = 'External order Number is Invalid'.

syst-msgty = 'E'.

raise e_message.

endif.