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: 

type-incompatible in ABAP code in ECC 6.0

Former Member
0 Kudos

DATA: bhdgi-hf(1) TYPE c,

...

bhdgi-t1(70) TYPE c.

...

DO VARYING bhdgi-hf FROM bhdgi-t10 NEXT bhdgi-t11.

IF bhdgi-hf <> space OR bhdgi-index GE 70.

EXIT.

ENDIF.

bhdgi-index = sy-index.

ENDDO.

...

SHIFT bhdgi-t1 BY bhdgi-index PLACES.

...

bhdgi-index1 = 0.

DO VARYING bhdgi-hf FROM bhdgi-t169 NEXT bhdgi-t168.

IF bhdgi-hf <> space OR bhdgi-index1 GE 70.

EXIT.

ENDIF.

bhdgi-index1 = sy-index.

ENDDO.

bhdgi-index1 = 70 - bhdgi-index1.

bhdgi-index2 = bhdgd-lines - 61. "YYYY

IF bhdgi-index1 >= bhdgi-index2.

WRITE bhdgi-t1 TO bhdgd-line1+26(bhdgi-index2).

ELSE.

bhdgi-index2 = bhdgi-index2 + 27.

WRITE bhdgi-t1 TO bhdgd-line1+bhdgi-index2.

ENDIF.

...

The above code segment is developed in ECC 6.0. i got the following error message.

BHDGI-T1 and BHDGI-HF are type-incompatible.

Please help me..

4 REPLIES 4

Former Member
0 Kudos

Hi

Check the data element of the both fields

BHDGI-T1 and BHDGI-HF

they might be different

in ECC6.0

if they are simiilar then only you can use like that

declare both of them of similar type and use

Regards

anji

Former Member
0 Kudos

Hi Anji,

Those two variables are declared out of elementary datatypes and they are not declared out of referencial types like dataelements.

Thanks,

Madhan.

0 Kudos

Hi,

Am facing the same issue in BHDGI-T1 and BHDGI-HF.

if you got the resolution please help

baizilpaulose
Explorer
0 Kudos

Compatible issue is coming because both the fields lengths are different. Please change your code declaring BHDGI-T1 and BHDGI-HF to the same length and data type