Skip to Content
Technical Articles
Author's profile photo Abhimanyu Sharma

CDS view performance Annotation for CDS view performance

Just want to share few interesting points on the CDS view performance Annotation for CDS view performance. SAP has released some guidelines to improve the performance of CDS views.

The best way to learn these guidelines is to learn from standard CDS views and apply in our custom views.


In most of the standard CDS views, we have seen below 3 annotations being used by SAP in order to improve performance. But I have seen we are not using it in our custom views which might impact performance while fetching data. Hence it would be good practice to use these annotations properly and benefit with performance.


  1. @ObjectModel.usageType.serviceQuality
  2. @ObjectModel.usageType.sizeCategory
  3. @ObjectModel.usageType.dataClass


( Note : In case where we want to see list of CDS view doesn’t have these annotations,  SAP has provided a standard table : DDHEADANNO. This table will have information of all the annotations being used in CDS views present in the system. So you can create a report program on this table where we can find out CDS views which doesn’t have above annotations with %usagetype% keyword. )


Valid values for serviceQuality: #A, #B, #C, #D, #X, #P


Valid values for sizeCategory: #S, #M, #L, #XL, #XXL




Now will see below charts where we will see in what cases we should use these annotations :  





Combination of Characteristics to be used for annotations in CDS views


Test Results :



Conclusion :


  1. Keep CDS views simple (in particular service-Quality A and B = #BASIC views)
  2. Amount of data persisted in S4 CDS views should not exceed 20% of the overall data volume of  the system.
  3. In transactional processing, only use simple CDS views accessed via CDS key
  4. Expose only required fields –define associations to reach additional fields when requested

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo ASHOK KUMAR

      Excellent article, keep up the good work!!

      Author's profile photo Abhilash Pradhan
      Abhilash Pradhan

      Excellent blog , helped me understand the concepts of these 3 .

      Author's profile photo Heiko Gerwens
      Heiko Gerwens

      No doubts that these annotations are useful also during custom development. They are meant to describe some characteristics of the CDS view with respect to their performance behavior in CDS queries. However, they should not have any impact on CDS query performance, because annotations are not even "known" by HANA. In your example you have probably observed another effect unrelated to these annotations. Would be great if you can share some more details of your example to figure out the root cause of the observed performance differences.