<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Extend CDS view in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/extend-cds-view/m-p/12327905#M1991445</link>
    <description>&lt;P&gt;hi experts：&lt;/P&gt;
  &lt;P&gt;I have two CDS views, ztest_cds and ztex_cds.&lt;/P&gt;
  &lt;P&gt;ztest_cds was a normal view. ztex_cds was a view that extends ztest_cds.&lt;/P&gt;
  &lt;P&gt;In ztex_cds, i association another table.When I active ztest_cds,errors was occurs.&lt;/P&gt;
  &lt;P&gt;this is error message.&lt;/P&gt;
  &lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/1903302-1.png" /&gt;&lt;/P&gt;
  &lt;P&gt;when I double click, it come ztex_cds, click active, it's right.NO error and warning.&lt;/P&gt;
  &lt;P&gt;ztest_cds code:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;@AbapCatalog.sqlViewName: 'zt_cds'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'test cds'
define view ztest_cds as select from sflight 
association [1..1] to spfli 
 on sflight.carrid = spfli.carrid
 and sflight.connid = spfli.connid{
    key carrid,
    key connid,
    key fldate,
    price,
    currency
}&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;ztex_cds code:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;@AbapCatalog.sqlViewAppendName: 'ztextend_cds'
@EndUserText.label: 'test extend cds'
extend view ztest_cds
with ztex_cds 
association to sbook as _book
            on _book.carrid = sflight.carrid
            and _book.connid = sflight.connid
 association [1..1] to scustom as _cust
             on _cust.id = _book.customid{
    _book.bookid,
    _book.customid,
    _cust.id,
    _cust.name,
    _cust.form,
    _cust.street
 
} 
&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;somebody can help me ?&lt;/P&gt;
  &lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Mon, 22 Mar 2021 01:54:44 GMT</pubDate>
    <dc:creator>JamesG</dc:creator>
    <dc:date>2021-03-22T01:54:44Z</dc:date>
    <item>
      <title>Extend CDS view</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/extend-cds-view/m-p/12327905#M1991445</link>
      <description>&lt;P&gt;hi experts：&lt;/P&gt;
  &lt;P&gt;I have two CDS views, ztest_cds and ztex_cds.&lt;/P&gt;
  &lt;P&gt;ztest_cds was a normal view. ztex_cds was a view that extends ztest_cds.&lt;/P&gt;
  &lt;P&gt;In ztex_cds, i association another table.When I active ztest_cds,errors was occurs.&lt;/P&gt;
  &lt;P&gt;this is error message.&lt;/P&gt;
  &lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/1903302-1.png" /&gt;&lt;/P&gt;
  &lt;P&gt;when I double click, it come ztex_cds, click active, it's right.NO error and warning.&lt;/P&gt;
  &lt;P&gt;ztest_cds code:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;@AbapCatalog.sqlViewName: 'zt_cds'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'test cds'
define view ztest_cds as select from sflight 
association [1..1] to spfli 
 on sflight.carrid = spfli.carrid
 and sflight.connid = spfli.connid{
    key carrid,
    key connid,
    key fldate,
    price,
    currency
}&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;ztex_cds code:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;@AbapCatalog.sqlViewAppendName: 'ztextend_cds'
@EndUserText.label: 'test extend cds'
extend view ztest_cds
with ztex_cds 
association to sbook as _book
            on _book.carrid = sflight.carrid
            and _book.connid = sflight.connid
 association [1..1] to scustom as _cust
             on _cust.id = _book.customid{
    _book.bookid,
    _book.customid,
    _cust.id,
    _cust.name,
    _cust.form,
    _cust.street
 
} 
&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;somebody can help me ?&lt;/P&gt;
  &lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 01:54:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/extend-cds-view/m-p/12327905#M1991445</guid>
      <dc:creator>JamesG</dc:creator>
      <dc:date>2021-03-22T01:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: Extend CDS view</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/extend-cds-view/m-p/12327906#M1991446</link>
      <description>&lt;P&gt;Hi Wei,&lt;/P&gt;&lt;P&gt;in which release are you working on?&lt;/P&gt;&lt;P&gt;You are accessing the association target _book in the on-condition of your association _cust. Instead, I recommend you to define it like this:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;@AbapCatalog.sqlViewAppendName: 'ztextend_cds'
@EndUserText.label: 'test extend cds'
extend view ztest_cds
with ztex_cds 
association to sbook as _book
            on _book.carrid = sflight.carrid
            and _book.connid = sflight.connid

 association [1..1] to scustom as _cust
             on _cust.id = $projection.customid
{
    _book.bookid,
    _book.customid,
    _cust.id,
    _cust.name,
    _cust.form,
    _cust.street
 
} &lt;BR /&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Hope this helps!&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;Fabian Fellhauer&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 14:40:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/extend-cds-view/m-p/12327906#M1991446</guid>
      <dc:creator>fabianfellhauer</dc:creator>
      <dc:date>2021-08-24T14:40:38Z</dc:date>
    </item>
  </channel>
</rss>

