Skip to Content

ABAP CDS View parameters in JOIN's

Oct 25, 2016 at 09:27 AM


avatar image
Former Member

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: 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

avatar image
Former Member Dec 06, 2016 at 08:30 AM

Hi Malcolm,

Could you solve this?

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



10 |10000 characters needed characters left characters exceeded