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: 

Create infoset based on indirect join

GOESSLINGL
Discoverer
0 Kudos
477

Hi there,

I don't have much ABAP knowledge but I need to create a infoset which joins VIBDOBJASS-OBJNRTRG and IFLOS-TPLNR. 

The problem is, OBJNRTRG has this short 2 letter string at the front of the entry which indicates the type of object (its like 2 concatenated fields)

To join on IFLOS-TPLNR, I would need to remove this 2 letter string.

Here's an example

VIBDOBJASS-OBJNRTRG

IF?0000000000000xxxxx

IFLOS-TPLNR

?0000000000000xxxxx

 

How can I make such a query? Do I create an additional field with that in the record processing code? could you provide some guidance how this would actually be structured technically?

3 REPLIES 3

flow82er
Explorer
0 Kudos
408

Hi!

You should be able to solve this with substring within the join-clause.

Example:

SELECT FROM usr01
  LEFT JOIN usr02 ON SUBSTRINGusr01~bname310 =  usr02~BNAME )
  INTO TABLE @DATA(lt_users.

Cheers,

ben

HeikeH
Explorer
391

Take IFLOT-OBJNR with IFLOT-TPLNR = IFLOS-TPLNR and IFLOT-OBJNR = VIBDOBJASS-OBJNRTRG

hth

0 Kudos
362

Thank you, though this was an alternate solution to the problem it meets the requirement.

LG