SAP Home Learn Build Integrate Model Operate Extend with AI ConnectTutorial navigator Knowledge Graph API Devtoberfest Developer Advocates App Space

Manage my Account SAP Devs YouTube ↗ Learnings ↗ Community ↗ Provide Feedback ↗
Logout
โคข Open full site

Create SQLScript User Defined Libraries

Leveraging SQLScript in Stored Procedures, User Defined Functions, and User Defined Libraries

Overview

🎓 intermediate 15 min. SAP HANAIntermediateSqlSAP HANA CloudSAP Business Application Studio

You will learn

  • โœ”How to create SQLScript User Defined Libraries
Rich Heilman R Rich Heilman November 1, 2022
Created by February 11, 2021
Contributors

Prerequisites

Prerequisites

Steps

Intro

Libraries are designed to group related variables, functions, and procedures together within a common object. These library members can either be exposed using the PULBIC keyword, or set to only be consumable from within the library itself using the PRIVATE keyword.


Step 1 Create new library
โ€”

  1. Return to the SAP Business Application Studio and right click on the src folder and choose New Folder.

    editor
    editor

  2. Enter the name of the folder as libraries and click OK.

    dialog
    dialog

  3. Use what you have learned in previous tutorials and create a new SAP HANA Database Artifact using the SAP HANA: Create SAP HANA Database Artifact command from the View menu.

    command
    command

  4. Make sure to select the libraries folder, and choose Library as the Artifact Type, then give the name as masterdata. Click Create

    wizard
    wizard

Step 2 Enter the library code
+
Step 3 Create a procedure
+
Step 4 Save, deploy, run and Cceck results
+

Resources

Discussion

Share feedback on this tutorial or join the conversation in SAP Community.

Submit detailed feedback Discuss in Community
Steps
Step 1 of 4
1. Create new library 2. Enter the library code 3. Create a procedure 4. Save, deploy, run and Cceck results

Learn more →