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: 

Problem in currency and quantity field

Former Member
0 Kudos

Hi,

I have done a couple of BDC and watched that if some currency or quantity field is there and i want to run the BDC the particular currency/quantity field will not populate the value inspite of i have declared the same table field that it refers to in the screen in the internal table.

But, if i declare a character string in the internal field having same length as the screen field it will populate at run time. Why so?

Regards

Sandeep

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Sandeep,

This is a common problem, when carrying out BDC.

For example, while recording you met with the 2 fields --> MSEG-DMBTR (Curr) and MSEG-MENGE(Quantity).

  • Go to SE11 --> MSEG --> Search for DMBTR --> Double click on the Data Element i.e. DMBTR --> Double Click on the domain WERTZ --> You can see under the block Output Characteristics : Output Length = 16.

While declaring the TYPES Structure, make it CHAR(16).

  • Similarly for MENGE --> Data Element : MENGE_D --> Domain : MENGE13 --> Output Length = 17.

Make it CHAR(17).

Consider this technique as the Rule-of-Thumb while doing BDC.

Regards,

Abir

***********************************

  • Don't forget to award points *

4 REPLIES 4

Former Member
0 Kudos

Hi Sandeep,

Because in the BDC you will check the values of each field with '/'. Since currency or quantity field cannot be compared with '/' the program will dump. But if you convert to character. Then this character field value with check with '/' and proceed further without any error.

Regards

Arun

Former Member
0 Kudos

Hai,

What ever might be your Case? First declare all Quality and Currency fields into <b>Character</b>.

Then tell us exactly , the problem?

Thanks

Manju

Former Member
0 Kudos

Hi

This is very common problem. You need to populate the value in the following manner:

for currency use: write value to bdc_tab_val currency 'USD' (for US, INR for India)

for quantity use: write value to bdc_tab_val unit unit_code.

you can get the unit_code from T006.

you can get Currency code form TURC

Regards,

Navneet

Former Member
0 Kudos

Hi Sandeep,

This is a common problem, when carrying out BDC.

For example, while recording you met with the 2 fields --> MSEG-DMBTR (Curr) and MSEG-MENGE(Quantity).

  • Go to SE11 --> MSEG --> Search for DMBTR --> Double click on the Data Element i.e. DMBTR --> Double Click on the domain WERTZ --> You can see under the block Output Characteristics : Output Length = 16.

While declaring the TYPES Structure, make it CHAR(16).

  • Similarly for MENGE --> Data Element : MENGE_D --> Domain : MENGE13 --> Output Length = 17.

Make it CHAR(17).

Consider this technique as the Rule-of-Thumb while doing BDC.

Regards,

Abir

***********************************

  • Don't forget to award points *