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: 

Linking table BSEG and PA0001 to display PA0001-SNAME

Former Member
0 Kudos
178

I am working on a report where I am facing problem with field length compatibility.

I have to pass value of field BSEG-HZUON to PA0001-PERNR and display SNAME in the output.

But the field length of HZUON and PERNR does not match each time, hence SNAME is displayed as blank in the output for these cases.

Please suggest a solution to this problem or possibility of using some other field as a linkage between tables BSEG and PA0001.

1 REPLY 1

Former Member
0 Kudos
78

Hi,

Yes, you are right. You can not link based on these fields.

Possible solutions:

1. Within a SELECT and ENSSELECT on bseg

move hzuon to a workfield

SELECT on pa0001 using the workfield

2. SELECT all BSEG data into an internal table (with an additional field PERNR)

Loop over the internal table filling the pernr.

SELECT all PA0001 data into an other internal table with the FOR ALL ENTRIES

Combine the internal tables.

Succes.