on 03-06-2017 2:45 AM - last edited on 02-03-2024 9:17 PM by postmig_api_4
Hi, experts.
I want to use subquery, subselect concepts in my ABAP CDS.
What I want to do is similar to SQL below.
select
name,
round(sum(amount_paid) / (select amount_paid from order_items) * 100.0, 2) as pct
from order_items
group by 1
order by 2 desc;
-> to calculate percent of revenue each items
SELECT *
FROM flights
WHERE origin in ( SELECT code FROM airports WHERE elevation > 2000);
-> using subquery in where clause
I'm not sure whether this concept is available in ABAP CDS.
Or do I make additional view and use join or association?
Hi,
No, sub-queries are not supported in CDS views as of now.
Regards,
Deo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.