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

Problem with BDC

Former Member
0 Likes
989

Hi,

I am having problem with BDC while transferring the field value to BDCDATA structure. Below is the coding part. I am getting FVAL in debug mode but, it's not passing into bdctab-val.

FORM BDC_FIELD USING fnam FVAL.

CLEAR bdctab.

IF not FVAL is initial.

bdctab-fnam = fnam.

bdctab-fval = FVAL.

APPEND bdctab.

endif.

ENDFORM.

Kindly advice me on this issue.

7 REPLIES 7
Read only

Former Member
0 Likes
962

Hi,

There is nothing wrong with this code. Please check it again.

When you say FVAL is not getting is populate, is it only for one record or for all record.?

Regards,

RS

Read only

0 Likes
962

Hi,

Thanks for your quick response.

perform bdc_field using 'MARC-LGFSB'

MARC-LGFSB. "'1000'.

perform bdc_field using 'BDC_CURSOR'

'MARC-PLIFZ'.

perform bdc_field using 'MARC-PLIFZ'

i_ekpo-plifz.

FAVL is not populating for only one record. i.e in above while passing i_ekpo-plifz to MARC-PLIFZ. In debug mode i_ekpo-plifz contains value but it's not assigning into bdctab-fval.

FORM BDC_FIELD USING fnam FVAL.

CLEAR bdctab.

IF not FVAL is initial.

bdctab-fnam = fnam.

bdctab-fval = FVAL.

APPEND bdctab.

endif.

ENDFORM.

Read only

0 Likes
962

Hi,

There is nothing wrong with your code.

Please follow these steps and check FVAL each point.

- Debug you code, When you do perform bdc_field using 'MARC-PLIFZ' i_ekpo-plifz, Check the value of i_ekpo-plifz.

- Whe program goes into form routine BDC_FIELD, check the value of FVAL.

- If FVAL is not initial and you are assinging values to bdctab-fval, check the value of FVAL.

- Once the APPEND bdctab statement is exexute, display whole table content and check very last entry. See what is the values in fnam and fval.

Please check these and let me know.

Regards,

RS

Read only

0 Likes
962

Hi,

In debug mode, Whe program goes into form routine BDC_FIELD, value for FVAL is exist. But, bdctab-fval is not getting value of FVAL . I am really wondering why it's not taking the value.

Regards,

Bharat.

Read only

0 Likes
962

Hi..,

Check the name that is assigned to the field bdctab-fval = FVAL.

whether it is FVAL or not...

ur code is correct !! can u post ur complete code here !!

regards,

sai ramesh

Read only

Former Member
0 Likes
962

Hi all,

Thanks for the help...

Read only

0 Likes
962

Hi Bharat,

Please try to refresh your bdcdata table after performing the form every time. I too came across some errors while doing this. I refreshed the i_bdcdata after the call transaction routine and it worked fine. Please try that.

Regards,

Buvana