Skip to Content
1
Jun 17, 2021 at 06:01 AM

When to use Define View Entity / Define View ?

286 Views

In the context of RAP, we are using "define root view entity" for main projection CDS View as well as Main Interface CDS View, as that is the main entity of the business object.

For the remaining composition views, we are using "define view entity" without root keyword, as that is not the top most entity of the business object.. This much I have understood.
But In our company, we are using remaining all dependent cds views which are used for value helps, for getting texts...etc, using "define view" with out even entity....

I read few blogs and got basic differences between "define view entity" and "define view", as one got ddic view, for other no need.

But when exactly we need to use define view / define view entity ?

Can we use for all cds views.... define view entity , except root view ?

Kindly share your knowledge on this.

Thanks in advance.