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

Doubt in type conversions

Former Member
0 Likes
441

Hi gurus,

I retrive the vbelv and vbeln values from VBFA table into my internal table.

In that some vbeln values are equal to tanum values in LTAP table.

for this i wrote the select query like below.

if gt_vbfa is not initial.

select

tanum

nistm

from ltap

into table gt_ltap

for all entries in gt_vbfa

where tanum = gt_vbfa-vbeln.

But is shows error, Why because, the type of the TANUM field is NUMC and the type of the VBELN field is CHAR.

But the values of vbeln are equal to tanum.

How can i retrive tanum values for corresponding vbeln values.

Please can any one suggest me on this issue.

Thanks in Advance.

Thanks and Regards

Siri...

2 REPLIES 2
Read only

Former Member
0 Likes
412

Hi,

the definition all fields with same name from gt_ltap and gt_vbfa must be the same type.

Otherwise :

gt_ltap

for all entries in gt_vbfa

this can`t work.

Regards

Nicole

Read only

Former Member
0 Likes
412

Hi siri,

You do one thing declare the another field in your internal table

with refer to ltap-tanum

like as follows.

data : begin of itab occurs 0,

f1,

f2,

v_tanum like ltap-tanum,

end of itab.

loop at itab.

itab-v_tanum = itab-vbeln.

modify itab trnsporting v_tanum.

clear itab.

endloop.

then go for the selection....

if gt_vbfa-v_tanum is not initial.

select

tanum

nistm

from ltap

into table gt_ltap

for all entries in gt_vbfa

where tanum = gt_vbfa-v_tanum.

endif.

Hope your problem will be solved.

Regards,

Madan.