FUNCTION MODULE – CONVERSION_EXIT_ALPHA_OUTPUT : REMOVE ZERO

Kebalikan dari CONVERSION_EXIT_ALPHA_INPUT , CONVERSION_EXIT_ALPHA_OUTPUT menghapus awalan kosong (0) di dalam karakter angka.
Pada kali ini, penulis akan membuat sebuah report di SAP , untuk menghapus kosong di karakter awal angka “0000000090” menjadi “90”
Pola :

FUNCTION CONVERSION_EXIT_ALPHA_OUTPUT.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*"  IMPORTING
*"     VALUE(INPUT) TYPE  CLIKE
*"  EXPORTING
*"     VALUE(OUTPUT) TYPE  CLIKE
*"----------------------------------------------------------------------
 
CALL 'CONVERSION_EXIT_ALPHA_OUTPUT' ID 'INPUT'  FIELD INPUT
ID 'OUTPUT' FIELD OUTPUT.
 
ENDFUNCTION.

Implementasi di SE38 (Abap Editor)

REPORT  ywhy_test.
 
"------------------- VARIABLE
DATA : INPUT(10) TYPE  C,
OUTPUT(10)  TYPE  c.
 
INPUT = '0000000090'.
 
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
EXPORTING
input         = input
IMPORTING
OUTPUT        = output
.
 
WRITE output.

Hasil :

FUNCTION MODULE - CONVERSION_EXIT_ALPHA_INPUT : REMOVE ZERO

FUNCTION MODULE – CONVERSION_EXIT_ALPHA_INPUT : REMOVE ZERO

Wahyu Amaldi has written 74 articles

Hi Reader, thank you for read this article, i hope this article can be useful.
If you will share knowladge to me, dont forget contact to me.

Email 1 : wahyu.amaldi@outlook.com
Email 2 : wahyu.amaldi@ilmuprogram.com

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>