Skip to content

Latest commit

 

History

History
32 lines (18 loc) · 2.36 KB

File metadata and controls

32 lines (18 loc) · 2.36 KB

Exercise 7 - Create HANA Stored Procedure and Expose as CAP Service Function (SAP HANA Cloud)

In this exercise we will further combine SAP HANA Cloud native artifacts with the SAP Cloud Application Programming Model (CAP), and expose SQLScript procedures as service functions.

Perform all the steps in 👉 tutorial: Create HANA Stored Procedure and Expose as CAP Service Function (SAP HANA Cloud)

Summary

The goals of this exercise are vary similar to the previous one. Import and Expose an existing database artifact via CAP. But there are some major differences here for Stored Procedures. Unlike views they aren't exposed as entities but as functions or actions.

Questions for Discussion

  1. What's SQLSCRIPT_SYNC?

  2. Why did we have to redeploy to the HANA Database after adding the Calculation View to the CAP service but didn't need to do the same when adding the Stored Procedure?

  3. What's the difference between a function and an action?

  4. Why did we use module sap-hdb-promisfied instead of hdb directly?

  5. A note and not a question. There is a new, experimental feature to call stored procedures directly using cds.run introduced in the March 2022 version of CAP. You can read more about it here.

Further Study

Next

Continue to 👉 Exercise 8 - Deploy CAP with SAP HANA Cloud project as MTA