‎2018 May 15 5:52 PM
I created a cds view like below
SPAN { font-family: "Consolas"; font-size: 10pt; color: #000000; background: #FFFFFF; }
@AbapCatalog.sqlViewName: 'ZS4DEMOCDS'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'Inner Join'
define view ZS4DEMO_CDS
as select from sbook as b
inner join spfli as p on b.carrid = p.carrid
and b.connid = p.connid
inner join scustom as c on c.id = b.customid
{
b.customid,
b.bookid,
c.name,
b.fldate,
p.cityfrom,
p.cityto
}
and used in report program(se38) like below
SELECT * FROM zs4hcds_selv25 INTO TABLE @DATA(lt_demo)
i'm getting a warning like this
Use the associated entity "ZS4DEMO_CDS".
please tell me why i'm getting this.
and the performance is slower to below statement which is written directly in se38 report program.
SELECT b~customid,b~bookid,c~name,b~fldate,p~cityfrom,p~cityto INTO TABLE @DATA(lt_data)
FROM ( sbook AS b INNER JOIN spfli AS p ON b~carrid = p~carrid
AND b~connid = p~connid
INNER JOIN scustom AS c ON c~id = b~customid ).
‎2018 Jul 06 3:15 PM
Hi Ravichand S,
I would like to answer your ask about your message "Use the associated entity "ZS4DEMO_CDS"."
It's because you don't use right table.
You must use ZS4DEMO_CDS as table and not zs4hcds_selv25.
Example:
SELECT * FROM ZS4DEMO_CDS INTO TABLE @DATA(lt_demo) Correct
SELECT * FROM zs4hcds_selv25 INTO TABLE @DATA(lt_demo) Wrong
Regards,
Maurizio.
‎2018 Jul 06 3:15 PM
Hi Ravichand S,
I would like to answer your ask about your message "Use the associated entity "ZS4DEMO_CDS"."
It's because you don't use right table.
You must use ZS4DEMO_CDS as table and not zs4hcds_selv25.
Example:
SELECT * FROM ZS4DEMO_CDS INTO TABLE @DATA(lt_demo) Correct
SELECT * FROM zs4hcds_selv25 INTO TABLE @DATA(lt_demo) Wrong
Regards,
Maurizio.
‎2018 Jul 30 3:57 PM
‎2018 Jul 06 4:11 PM
‎2018 Jul 06 4:46 PM
‎2018 Jul 30 3:57 PM