Skip to Content
Product Information

CDS views vs LIS in PM. How to use CDS views to create your own queries

Level 1: Easy; 10 minutes read

Audience: Subject Matter Experts

Author: Ramandeep Goyal, SAP S/4HANA RIG EMEA

Introduction – In this blog, we will compare the information which is available in CDS views against PMIS (Plant Maintenance Information System) which is part of LIS (Logistics Information System). We will also discuss; how can we write queries using standard CDS views or how can custom CDS views be created from standard CDS views.

PMIS (LIS) vs CDS Views

Historically, we have been using LIS tables (mentioned below) for standard reports or custom reports in Plant Maintenance.

  • S061 Location and planning
  • S062 Object class and manufacturer
  • S063 Damage analysis 30
  • S064 Damage analysis
  • S065 Object statistics
  • S070 Breakdown statistics
  • S114 Vehicle Consumption Analysis
  • S115 Cost Evaluation
  • S116 Customer Analysis

As we know, these tables will not be available in future in S/4HANA because –

  • LIS operates on redundant data. Every business transaction not only updates the business documents, but also pre-aggregated data in LIS. Performance suffers, locking conflicts might occur, and memory is wasted
  • LIS operates on pre-aggregated data. It is not possible to drill down into the individual business documents. Multi-dimensional reporting (aka Slicing and dicing) is only possible for dimensions provided in the pre-aggregated data
  • LIS uses an old UI technology making multi-dimensional reporting clumsy

Please refer to SAP note 2267463 for further information on this.

Going forward, data for Plant Maintenance reports will be available in CDS (Core Data Services) views which is considered as future technology. As of now, LIS tables are available because all the information (which is available in LIS tables) is not available in CDS views. Customers can stop using LIS tables once all the information related to PM reporting requirements is available in CDS views. There will be notable improvement in the performance if reports are built using CDS views. Also, memory requirements will be lesser since information is stored in lesser number of tables.

The current list of CDS views for Asset Management can be found @ following link.

https://help.sap.com/viewer/8308e6d301d54584a33cd04a9861bc52/1909.002/en-US/bea52cb1d9784702a17ecc9f1137cba1.html

In terms of comparison, there is a CDS view for LIS table of location analysis. For technical objects and data related to manufacturer, there are few CDS views available. CDS views for Equipment, Equipment Data, Functional Locations etc. can be combined to generate a query which will give holistic view on the technical objects. Even CDS view for Equipment Install / Dismantle History can also be used to add additional information with regards to installation and dismantling of equipments on various functional locations.

There are Fiori apps for damage analysis and breakdown analysis which cover relevant LIS tables. These Fiori apps can also produce graphical views which are really interactive and provide better analysis to view the results.

LIS table for cost evaluation, is also available in CDS view “Maintenance Order Actual Cost Data”. This CDS view can be combined with additional CDS views like technical objects etc. which creating a custom CDS view. Required fields can be selected as needed to create custom queries.

LIS tables for Vehicle Consumption Analysis and Customer Analysis have not yet been made available as a CDS views. Most probably, they will be covered in the future releases of S/4HANA.

Please note that not all the CDS views can be used to create custom queries. There are certain CDS views which can be directly used to create custom queries. For example – I_MaintOrderActualCostDataCube – Maintenance order actual cost data. For others, you can create custom CDS views from the standard CDS views and then create queries against them. The process to create queries using standard CDS views or Custom CDS views will be explained in the following section of the document.

 

Create Custom CDS view from the Standard CDS View

To create custom CDS view, you need to you have the administration level access and BASIS team needs to create a role with the authorizations shown below and assign the role to user ID.

Once you have the authorization, you will be able to see and access tile “Custom CDS View”. Click on the same to go to “Custom CDS view”.

Search for the standard CDS view which you want to use as reference and press “Create”. System will import the standard CDS view and copy all the fields from the standard CDS view to start with. You may also add more CDS views needed in case you need your query to fetch data from multiple CDS views.

Give a name & label to the custom CDS view. Please note that blank spaces are not allowed in the name. Go to “Field Selection” to select the fields which you want to display in the custom CDS view. Also, mark this CDS view as Analytical and as Cube so that it can be used to create a custom query against it. CDS view should be marked as “Analytical” otherwise it will not be available for selection while creating custom query / report.

By default, system will display all the fields from the standard CDS view. You can select the fields as needed. The keys are selected by default and users are not allowed to deselect them. Selected fields are checked and moved to the right so that user can see the fields which are already selected. In case a field is selected by mistake or user doesn’t see the need of it; it can be removed by pressing “Remove Field” on the right side of selected field.

Once all the required fields are selected, you can save your custom CDS view as draft or publish it. You can also delete it if it is no longer needed and you need to create a new one. Custom CDS views can be edited to add new fields or remove existing fields.

As shown below, you can see the many standard CDS views come with existing joints to additional CDS views and their fields are already available for selection.  You may select additional fields from these CDS views as joints are already available between them. For example – the CDS view selected in our use case comes with additional CDS views mentioned below.  This functionality is only available when you create custom CDS view with reference to standard CDS view. This is one of the advantages of creating custom CDS view as additional CDS views are not available while creating query against standard CDS view.

 

Go to “Field Properties” if you need to add Semantic. For certain fields, Semantics are predefined by the system. For others, you can define as needed.

 

You can also define parameters and filters if needed. Once you are done with the changed, publish your CDS view so that it is available and can be used to write custom queries.

Create Custom Analytical Query – custom queries can be created with reference to standard CDS view or custom CDS views. Queries created with reference to standard CDS view will have access to fields from one CDS view only. However, queries created with reference to custom CDS views can fetch information from multiple standard CDS views.

Click on the tile “Custom Analytical Queries” to create a new query or edit your existing queries.

Press “New” on the next screen to create a new query and Enter name of the query. Also, select the data source from the drop-down list. Enter the label for the query on the next screen. At this stage, you can save the draft for the query or go for field selection.

 

 

Like custom CDS view, all the fields will be displayed. Select the fields which you want to display in your query / report. Selected fields will move to right side. Any unwanted field can be deleted as explained above while creating custom CDS view.

Once all the relevant fields are selected, go to “Display” to decide how the fields should be displayed in the report.

 

You can decide if a field should be displayed in a row or a column by selecting the axis. Few fields can be left as free so that they can be used for filters only. You can also move the fields up and down to decide their order of display in the query.

 

Once you are done, you can preview the results and make further changes as needed. Publish the query when you are OK with the results. Data can be filtered based upon any of the fields available in the query even if the field is not displayed in the report.

Once your query has been published, share the technical details as shown below with the Fiori consultant so that he can create a Fiori tile and assign it to a role where users can directly use the report.

 

Click on “View Browser” and search for your query.

 

Go into your query and share the information as shown below with the Fiori consultant.

 

Additional Information –

SAP S/4HANA Discovery

 

4 Comments
You must be Logged on to comment or reply to a post.
  • That’s a nice piece of writing.

    A really like to idea of not having redundant data in the system and replacing LIS with CDS views.

    What worries me though is that while talking the replacement we always focus on reporting of actual data, but somehow we say nothing about planning which is a big part of LIS. I’d say LIS planning is fundamental to integrated planning in SAP ERP solution.

    If we phase out LIS what tool shall be used for planning? Will it provide the same level of integration as LIS currently provides? Will the tool be covered with standard license or will it require additional licenses?

    BR

    Dominik Tylczynski