2008 Aug 27 6:12 AM
hi experts....
i have done a report where i have to upload data from
excel,(done using gui_upload) now my problem is when entering the
outbound delivery number as (e.g)800104 from tcode and enter
manually its accepting,
whereas when uploaded from excel i need to add two zero in
front (e.g) 00800104 for outbound delivery no to convert to SAP format
but excel does not allow adding zero in front
so my temp solution is converting to text and add two zero manually.
To overcome i included the Function module
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = likp-VBELN
IMPORTING
OUTPUT = likp-VBEL
but NO EFFECT...
Can you pls Suggest wat can be done .
Thanx in advance
Regards
Rachel
2008 Aug 27 6:17 AM
hi,
'CONVERSION_EXIT_ALPHA_INPUT' fm is used to get leading zeros in sap.
if u want leading zeros in EXCEL right click on left side top of excel sheet ,select format cells and select text.
now u can have leading zeros in excel.
hi experts....
i have done a report where i have to upload data from
excel,(done using gui_upload) now my problem is when entering the
outbound delivery number as (e.g)800104 from tcode and enter
manually its accepting,
whereas when uploaded from excel i need to add two zero in
front (e.g) 00800104 for outbound delivery no to convert to SAP format
but excel does not allow adding zero in front
so my temp solution is converting to text and add two zero manually.
To overcome i included the Function module
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = likp-VBELN
IMPORTING
OUTPUT = likp-VBEL
but NO EFFECT...
Can you pls Suggest wat can be done .
Thanx in advance
Regards
Rachel
2008 Aug 27 6:17 AM
hi,
'CONVERSION_EXIT_ALPHA_INPUT' fm is used to get leading zeros in sap.
if u want leading zeros in EXCEL right click on left side top of excel sheet ,select format cells and select text.
now u can have leading zeros in excel.
2008 Aug 27 6:46 AM
2008 Aug 27 6:19 AM
Hi,
1.It is well documented.
Check this:
Conversion exit ALPHA, external->internal
ALPHA conversion is used especially with account numbers. During conversion from the external to the internal format, the system checks to see if input in the INPUT field is purely numeric, that is, if this input consists only of numbers, possibly with spaces before and after them. If this is the case, then the number string is inserted right- justified in the display field OUTPUT and all spaces to the left of the value are filled with zeroes ('0'). If the input is not purely numeric, it is inserted in the display field from left to right and all extra spaces are filled with blanks.
Example:
(Input field and output field are both eight characters in length)
1. '1234 ' --> '00001234'
2. 'ABCD ' --> 'ABCD '
3. ' 1234 ' --> '00001234'
Conversion from the internal to the external format (function module CONVERSION_EXIT_ALPHA_OUTPUT) is undertaken in exactly the opposite manner.
Usage:
call function 'CONVERSION_EXIT_ALPHA_INPUT'
exporting
input = v_input
importing
output = v_output
exceptions
others = 1.
2.If failed these FM's ,then use concatenate key word for adding two zero's infront to that number.
Regards,
Shiva Kumar
2008 Aug 27 6:19 AM
Hi,
to overcome this problem all you need to do is,
when you read the Exel sheet data into the internal table
just loop thru it and add 2 zeroes to all the values.
OR
put a single quote in the excel file before the zeroes
' 00893..
Regards,
Samson Rodrigues.
2008 Aug 27 6:19 AM
hi arun
In EXCEL select that column A ( for eg if delivery no is A column) then right click FORMAT CELLS -> TEXT instead of General catorgy
Regards
Deva
2008 Aug 27 6:49 AM
2008 Aug 27 6:20 AM
if you cant change the excel file cell formatting then you can use command 'CONCATENATE' to add leading zeros
2008 Aug 27 6:21 AM
Hi,
This is a common issue.
You can solve this by below method.
data: l_text1(10) type c value '`',
l_out(20) type c.
concatenate l_text1 l_your_variable into l_out.Download l_out in excel sheet.
Regards,
Anversha
2008 Aug 27 10:40 AM
hi anversha ,
i really appreciate ur reply, thanx and i have tried that,
can u pls tell me what do u mean by download l_out
wat values to be passed in l_out
can u pls explain
thanx
Rachel
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |