Skip to Content
1

ABAP CDS View parameters in JOIN's

Oct 25, 2016 at 09:27 AM

327

avatar image

If I have an ABAP CDS View with parameters (CDS no. 1) and I need an inner join on that CDS View from another CDS View (CDS no. 2), how do I do it?

If it was the first table of the SELECT in the CDS, I could do it like this:

.......as select from CDS1 (stobjid:$parameters.stobjid, begda:$parameters.begda, endda:$parameters.endda)

But I can't do this when I am doing a JOIN on CDS No. 1 from CDS No. 2 (or at least it seems to me that I can't) and they also don't seem to go into the ON part of the JOIN.

The only way I can seemingly get this to work is like this:

join CDS1 ( stobjid : $parameters.p_stobjid )

But I do not want the stobjid to come from a parameter passed into CDS 2, I want it to come from an earlier JOIN in the CDS. ie.

join CDS1 ( stobjid : table.field )

Can anyone point me in the right direction?

thanks, Malcolm

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Kris Claes Dec 06, 2016 at 08:30 AM
0

Hi Malcolm,

Could you solve this?

I am encountering the same problem when trying to pass a date to the JOIN or ASSOCIATION.

Regards.

Kris

Share
10 |10000 characters needed characters left characters exceeded