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: 

Convert Quantity field to User profile format

Former Member
0 Kudos
2,030

Hi,

I have developed a BDC pgm, which will post QUANTITY field in QA12 transaction.

While fetching Quantity (LMENGEZUB) field from QALS table, the value is being fetched as 10.000 (which is just value 10)

I have set my user profile as 1.23.456,000

Now the pblm is i have to convert 10.000 as 10,000 (according to user profile).

Please help me out in solving this issue.

Thanks,

DhanaLakshmi M S

1 ACCEPTED SOLUTION

Former Member
0 Kudos
555

1) Better you change the user profile to the required format, then load the data. After loading revert the user profile setting.

2) Else use the below statement to convert the quantity into required format.

data: quan(13) type c.

move quantity to quan.

replace all occurances of '.' in quan with ',' .

4 REPLIES 4

Former Member
0 Kudos
556

1) Better you change the user profile to the required format, then load the data. After loading revert the user profile setting.

2) Else use the below statement to convert the quantity into required format.

data: quan(13) type c.

move quantity to quan.

replace all occurances of '.' in quan with ',' .

0 Kudos
555

Hi Chandrasekar,

Thanks for your reply. I need a functional module to convert this. There may be any type of decimal notation selected in User profile. so i need to change the field dynamically.

DhanaLakshmi M S

0 Kudos
555

No need for a function, With BDC quantity fields must be passed as CHAR. So do a write of your quantity field to a CHAR field and all will be well.

0 Kudos
555

Maen,

Thanks a lot. It solved my problem.

DhanaLakshmi M S