on 05-28-2011 10:46 AM
hai all,
Am having a requirement of generating a random number based on the type of Process.
Say if it is medical means I want it to be MEDxxxxx .
Is thr any FM Please send some suggestions...
Thanks in advance,
Nalla.B
Hi,
Create one FM and pass the Type "MED" or othere you want and use below FM to get the random number and append the passed type with returned random number. Finally return the appended number from your FM.
CALL FUNCTION 'QF05_RANDOM_INTEGER'
EXPORTING
ran_int_max = 1000
ran_int_min = 1
IMPORTING
ran_int = w_num
EXCEPTIONS
invalid_input = 1
OTHERS = 2.
Hope this will help!
Thanks!
Piyush
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
which process?
Every random number specific to application can be triggerd, you can find the badi or teh steps in that specific application
checlk SNR0
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
it sounds to me like the "random" number should be unique... I would advise you to use a number range for this.
Help-Link:
http://help.sap.com/saphelp_nw04/helpdata/en/1f/8310df4bc511d189750000e8322d00/content.htm
regards, Lukas
User | Count |
---|---|
89 | |
7 | |
7 | |
4 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.