Application Development and Automation 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: 
Read only

Dashed format & leading zeros

Former Member
0 Likes
942

Hi,

1) Iam getting the SSN from P0002.But my client requirement is the SSN format should be in Dashed format like XXX-XX-XXXX.How i will get the dashed format?

iam getting SSN like this.

w_MetLife_detail-rdssn = p0002-perid.

2)How i send the value with leading zeros.

for example for this query : Hourly employee( PA0008-LGART = 1001): pa0008-BET01

Send values with leading zeroes

i written the code like

w_MetLife_detail-rdempsalary = p0008-bet01.

Kinldy help me on this.

Regards,

Sujan

6 REPLIES 6
Read only

Former Member
0 Likes
846

Hi Sujan,

1) Iam getting the SSN from P0002.But my client requirement is the SSN format should be in Dashed format like XXX-XX-XXXX.How i will get the dashed format?
iam getting SSN like this.
w_MetLife_detail-rdssn = p0002-perid.

=> Try using USING EDIT MASK '___-__-____'.

2)How i send the value with leading zeros.
for example for this query : Hourly employee( PA0008-LGART = 1001): pa0008-BET01
Send values with leading zeroes

i written the code like 
w_MetLife_detail-rdempsalary = p0008-bet01.

=> Use Function module 'CONVERSION_EXIT_ALPHA_INPUT'

Regards

Shital

Read only

0 Likes
846

Hi,

can you explain cleary with coding?

Regards,

Sujan

Read only

0 Likes
846

Please give try from your side and let me know if it fails.

Read only

Former Member
0 Likes
846
call function 'CONVERSION_EXIT_AUFNR_INPUT'
  exporting
    input         = aufnr
 importing
   output        = lv_aufnr.

Use this function module to send values with leading zeros.

Regards,

Lalit Mohan Gupta.

Read only

Former Member
0 Likes
846

Hi Sujan,

Here is the sample code.

1) Iam getting the SSN from P0002.But my client requirement is the SSN format should be in Dashed format like XXX-XX-XXXX.

How i will get the dashed format?

iam getting SSN like this.

w_MetLife_detail-rdssn = p0002-perid.

W_METLIFE_DETAIL-RDSSN = 1234567890.

WRITE /: W_METLIFE_DETAIL-RDSSN USING EDIT MASK '___-___-____'.

2)How i send the value with leading zeros.

for example for this query : Hourly employee( PA0008-LGART = 1001): pa0008-BET01

Send values with leading zeroes

i written the code like

w_MetLife_detail-rdempsalary = p0008-bet01.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

EXPORTING

INPUT = W_METLIFE_DETAIL-RDEMPSALARY

IMPORTING

OUTPUT = W_METLIFE_DETAIL-RDEMPSALARY.

Thanks & regards,

Dileep .C

Read only

Former Member
0 Likes
846

Thanks for reply.

Regards,

Sujan