12-06-2018 5:19 AM
I am unable to use the Multiple Assocation in CDS view below my code
@AbapCatalog.sqlViewName: 'ZFI_GSTR2GL101'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'G/L 101 Service Invoice'
define view ZFI_CDS_GSTRGL101 as select distinct from zfi_gst2vekbe as a
association to zfi_cds_gstr2_po as gst2_po
on a.ebeln = gst2_po.ebeln
and a.ebelp = gst2_po.ebelp
association to bkpf as b on b.awkey = a.awkey
association to bseg as c1 on $projection.belnr = b.belnr and c1.buzid = 'M' and c1.zekkn = gst2_po.zekkn
{
a.ebeln,
a.ebelp,
a.zekkn,
a.bwart,
a.belnr as belnr1,
b.belnr,
b.gjahr
// Make association public
}
where a.bwart = '101'
and a.ebeln = '3600000028'
Getting Error when use the field c1.Hkont
12-06-2018 5:40 AM
12-06-2018 11:06 AM
12-13-2018 9:57 AM
You can use left outer join instead of Associations to achieve the requirement as there are no path expressions and cardinality present in your scenario.