diff --git a/tutorials/hana-clients-cf/hana-clients-cf.md b/tutorials/hana-clients-cf/hana-clients-cf.md index bc38e6a53..422c25501 100644 --- a/tutorials/hana-clients-cf/hana-clients-cf.md +++ b/tutorials/hana-clients-cf/hana-clients-cf.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition, programming-tool>node-js, software-product>sap-btp--cloud-foundry-runtime-and-environment, software-product>sap-business-technology-platform, software-product>sap-connectivity-service] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>node-js, software-product>sap-btp--cloud-foundry-runtime-and-environment, software-product>sap-business-technology-platform, software-product>sap-connectivity-service] primary_tag: software-product>sap-hana-cloud --- @@ -24,7 +24,7 @@ primary_tag: software-product>sap-hana-cloud ## Intro -In the previous tutorials, applications that queried SAP HANA were run on a local machine. In this tutorial, a simple application will be run within the SAP BTP which uses Cloud Foundry or within the SAP HANA, express edition which uses XS advanced (and is also based on Cloud Foundry). +In the previous tutorials, applications that queried SAP HANA were run on a local machine. In this tutorial, a simple application will be run within the SAP BTP which uses Cloud Foundry or within the SAP HANA on-premise which uses XS advanced (and is also based on Cloud Foundry). For additional details, consult [Developing Applications on SAP BTP, Cloud Foundry runtime](https://learning.sap.com/learning-journeys/developing-applications-on-sap-btp-cloud-foundry-runtime) or [The XS Advanced Programming Model](https://help.sap.com/docs/SAP_HANA_PLATFORM/4505d0bdaf4948449b7f7379d24d0f0d/df19a03dc07e4ba19db4e0006c1da429.html). @@ -32,7 +32,7 @@ For additional details, consult [Developing Applications on SAP BTP, Cloud Found ### Get started with the Command Line Interface (CLI) -The command line interface (CLI) for Cloud Foundry is named `cf` while the CLI used for apps running in SAP HANA, express edition is named `xs`. +The command line interface (CLI) for Cloud Foundry is named `cf` while the CLI used for apps running in SAP HANA on-premise is named `xs`. 1. Check to see if you have the CF CLI installed and verify the version. @@ -372,7 +372,7 @@ For additional details see: ### Connect from the Node.js app running in the cloud to an on-premise database (optional) -The [Cloud Connector](https://help.sap.com/docs/connectivity/sap-btp-connectivity-cf/cloud-connector#loioe6c7616abb5710148cfcf3e75d96d596__context) enables communication from the SAP BTP running in the public internet to securely connect to a configured on-premise system such as SAP HANA, express edition. The following steps demonstrate how to do this with the previously deployed app `nodeQueryCF`. +The [Cloud Connector](https://help.sap.com/docs/connectivity/sap-btp-connectivity-cf/cloud-connector#loioe6c7616abb5710148cfcf3e75d96d596__context) enables communication from the SAP BTP running in the public internet to securely connect to a configured on-premise system such as SAP HANA on-premise. The following steps demonstrate how to do this with the previously deployed app `nodeQueryCF`. 1. Follow step 3 in [Access Remote Sources with SAP HANA Database Explorer](hana-dbx-remote-sources) to install and configure the Cloud Connector. @@ -509,7 +509,6 @@ The [Cloud Connector](https://help.sap.com/docs/connectivity/sap-btp-connectivit }) }) } - ``` 6. Redeploy the app. @@ -519,7 +518,7 @@ The [Cloud Connector](https://help.sap.com/docs/connectivity/sap-btp-connectivit cf push ``` -7. The application running in the cloud, is now accessing data from an on-premise SAP HANA, express instance. +7. The application running in the cloud, is now accessing data from an on-premise SAP HANA instance. ![Result](proxy-result.png) diff --git a/tutorials/hana-clients-choose-hana-instance/hana-clients-choose-hana-instance.md b/tutorials/hana-clients-choose-hana-instance/hana-clients-choose-hana-instance.md index 1b90c7b3d..7411cb9b0 100644 --- a/tutorials/hana-clients-choose-hana-instance/hana-clients-choose-hana-instance.md +++ b/tutorials/hana-clients-choose-hana-instance/hana-clients-choose-hana-instance.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 20 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- @@ -42,10 +42,10 @@ For more information on SAP HANA Cloud, consult [Introduction to SAP HANA Cloud] There are multiple versions of SAP HANA. The information below is a list of links for the documentation of each version. -| Version | Notes -| :------------- | :------------- -| [SAP HANA Platform 2.0](https://help.sap.com/docs/SAP_HANA_PLATFORM) | Released in November 2016. Current version is 2.0 SPS 08, which was released on Nov 20th, 2024. -| **[SAP HANA Cloud](https://help.sap.com/docs/hana-cloud)** | Released in March 2020. New features are released quarterly. +| Version | Notes +| -------- | ------ | +| [SAP HANA Platform 2.0](https://help.sap.com/docs/SAP_HANA_PLATFORM) | Released in November 2016. Current version is 2.0 SPS 08, which was released on Nov 20th, 2024. | +| **[SAP HANA Cloud](https://help.sap.com/docs/hana-cloud)** | Released in March 2020. New features are released quarterly. | ### SAP HANA Cloud @@ -149,7 +149,7 @@ Congratulations! You have connected to SAP HANA Cloud and performed a few querie >This step only needs to be completed if you currently do not have access to an SAP HANA Instance and did not set up an SAP HANA instance using the SAP HANA Cloud free tier as explained in step 3. -A default installation will contain one [system](https://help.sap.com/docs/SAP_HANA_PLATFORM/6b94445c94ae495c83a19646e7c3fd56/39da3d057f56427ab1bb7f738ca9e7ce.html) database named **SYSTEMDB** and one [tenant](https://help.sap.com/docs/SAP_HANA_PLATFORM/6b94445c94ae495c83a19646e7c3fd56/623afd167e6b48bf956ebb7f2142f058.html) database named **HXE**. +A default installation will contain one [system](https://help.sap.com/docs/SAP_HANA_PLATFORM/6b94445c94ae495c83a19646e7c3fd56/39da3d057f56427ab1bb7f738ca9e7ce.html) database named **SYSTEMDB** and one [tenant](https://help.sap.com/docs/SAP_HANA_PLATFORM/6b94445c94ae495c83a19646e7c3fd56/623afd167e6b48bf956ebb7f2142f058.html) database which in this example is named **HXE**. The system database contains information about the tenant database(s) and is used for overall administration. The default port for the system database is **39013**. Later in this tutorial mission, a connection to the tenant database will be made and tables will be created and populated with data. For more information, see [SAP HANA Tenant Databases Operations Guide](https://help.sap.com/docs/SAP_HANA_PLATFORM/78209c1d3a9b41cd8624338e42a12bf6/0ba9f43aed594a449d497fabf6bc381e.html). diff --git a/tutorials/hana-clients-dot-net-core/hana-clients-dot-net-core.md b/tutorials/hana-clients-dot-net-core/hana-clients-dot-net-core.md index e8028f478..d0969ae63 100644 --- a/tutorials/hana-clients-dot-net-core/hana-clients-dot-net-core.md +++ b/tutorials/hana-clients-dot-net-core/hana-clients-dot-net-core.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- @@ -104,7 +104,7 @@ In order for the shell to recognize that the .NET SDK is installed and for any ` // encrypt and sslValidateCertificate should be true for HANA Cloud connections // As of SAP HANA Client 2.6, connections on port 443 enable encryption by default // sslValidateCertificate should be set to false when connecting - // to an SAP HANA, express edition instance that uses a self-signed certificate. + // to an on-premise SAP HANA instance that uses a self-signed certificate. { conn.Open(); diff --git a/tutorials/hana-clients-entity-framework/hana-clients-entity-framework.md b/tutorials/hana-clients-entity-framework/hana-clients-entity-framework.md index d7c299cc8..798717b7e 100644 --- a/tutorials/hana-clients-entity-framework/hana-clients-entity-framework.md +++ b/tutorials/hana-clients-entity-framework/hana-clients-entity-framework.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- diff --git a/tutorials/hana-clients-golang/hana-clients-golang.md b/tutorials/hana-clients-golang/hana-clients-golang.md index a97076db4..b69c6d343 100644 --- a/tutorials/hana-clients-golang/hana-clients-golang.md +++ b/tutorials/hana-clients-golang/hana-clients-golang.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- diff --git a/tutorials/hana-clients-hdbsql/hana-clients-hdbsql.md b/tutorials/hana-clients-hdbsql/hana-clients-hdbsql.md index 00021fa94..354b0595b 100644 --- a/tutorials/hana-clients-hdbsql/hana-clients-hdbsql.md +++ b/tutorials/hana-clients-hdbsql/hana-clients-hdbsql.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition, programming-tool>sql] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>sql] primary_tag: software-product>sap-hana-cloud --- @@ -23,7 +23,7 @@ primary_tag: software-product>sap-hana-cloud ## Intro -HDBSQL is used in this tutorial as it is part of the SAP HANA client install. HDBSQL is a basic tool for executing SQL scripts and providing an interface for interactive queries. Another option to execute SQL operations is the [SQL Console](hana-dbx-hcc) that is part of SAP HANA Cloud Central or the [SAP HANA database explorer](group.hana-cloud-get-started) which is part of an on-premise install of the SAP HANA Cockpit or a server + applications SAP HANA, express edition install. +HDBSQL is used in this tutorial as it is part of the SAP HANA client install. HDBSQL is a basic tool for executing SQL scripts and providing an interface for interactive queries. Another option to execute SQL operations is the [SQL Console](hana-dbx-hcc) that is part of SAP HANA Cloud Central or the [SAP HANA database explorer](group.hana-cloud-get-started) which is part of an on-premise install of the SAP HANA Cockpit. --- @@ -37,7 +37,7 @@ This step demonstrates how to connect to a SAP HANA instance using [HDBSQL](http hdbsql -h | more ``` -2. Connect to either SAP HANA Cloud or SAP HANA, express edition using host, port, and credentials. Details on where to find these values are covered in the third and fifth steps of the [first tutorial](hana-clients-choose-hana-instance) in this mission. +2. Connect to either SAP HANA Cloud or SAP HANA on-premise instance using host, port, and credentials. Details on where to find these values are covered in the third and fifth steps of the [first tutorial](hana-clients-choose-hana-instance) in this mission. - To connect to SAP HANA Cloud, see the following general command. @@ -53,7 +53,7 @@ This step demonstrates how to connect to a SAP HANA instance using [HDBSQL](http ![Connect with hdbsql](connect-with-hdbsql.png) - - For SAP HANA, express edition, there are two options shown below to connect. + - For SAP HANA on-premise, there are two options shown below to connect. ```Shell hdbsql -n :39015 -u -p @@ -61,7 +61,7 @@ This step demonstrates how to connect to a SAP HANA instance using [HDBSQL](http hdbsql -n -d -i -u -p ``` - Below are two connection examples for SAP HANA, express edition. + Below are two connection examples for an on-premise SAP HANA instance. ```Shell hdbsql -n :39015 -u SYSTEM -p your_password @@ -149,7 +149,7 @@ This step demonstrates how to connect to a SAP HANA instance using [HDBSQL](http ![Connect to HANA Cloud](Connect-to-host-server-cloud.png) - Notice that for the HANA, express edition, the version number is 2.x. + Notice that for the on-premise instance, the version number is 2.x. ![Connect to HXE](Connect-to-host-server.png) diff --git a/tutorials/hana-clients-install/hana-clients-install.md b/tutorials/hana-clients-install/hana-clients-install.md index 856bebdb8..e14862512 100644 --- a/tutorials/hana-clients-install/hana-clients-install.md +++ b/tutorials/hana-clients-install/hana-clients-install.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 10 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- diff --git a/tutorials/hana-clients-jdbc/hana-clients-jdbc.md b/tutorials/hana-clients-jdbc/hana-clients-jdbc.md index 5300f4e55..fbe0c9b8e 100644 --- a/tutorials/hana-clients-jdbc/hana-clients-jdbc.md +++ b/tutorials/hana-clients-jdbc/hana-clients-jdbc.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud\,-sap-hana-database, software-product>sap-hana, software-product>sap-hana\,-express-edition, programming-tool>java] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>java] primary_tag: software-product>sap-hana-cloud --- @@ -144,7 +144,7 @@ See [JDBC Command-Line Connection Options](https://help.sap.com/docs/SAP_HANA_CL //As of SAP HANA Client 2.6, connections on port 443 enable encryption by default //validateCertificate should be set to false when connecting - //to an SAP HANA, express edition instance that uses a self-signed certificate. + //to an SAP HANA on-premise instance that uses a self-signed certificate. //As of SAP HANA Client 2.7, it is possible to direct trace info to stdout or stderr //"jdbc:sap://10.11.123.134:39015/?encrypt=true&validateCertificate=false&traceFile=stdout&traceOptions=CONNECTIONS", "User1", "Password1"); @@ -241,7 +241,7 @@ Visual Studio Code provides plugins for Java and can be used to debug an applica `DBeaver` is a free and open-source database tool and can be used with the SAP HANA JDBC driver. -The following steps demonstrate how to configure `DBeaver` to connect to SAP HANA Cloud or SAP HANA, express edition using the JDBC driver. +The following steps demonstrate how to configure `DBeaver` to connect to SAP HANA Cloud or SAP HANA on-premise instance using the JDBC driver. 1. [Download](https://dbeaver.io/download/), install or unzip, and run the community edition of `DBeaver`. diff --git a/tutorials/hana-clients-node/hana-clients-node.md b/tutorials/hana-clients-node/hana-clients-node.md index 0ad244c80..24b92c5ea 100644 --- a/tutorials/hana-clients-node/hana-clients-node.md +++ b/tutorials/hana-clients-node/hana-clients-node.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 20 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition, programming-tool>node-js] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>node-js] primary_tag: software-product>sap-hana-cloud --- @@ -211,7 +211,7 @@ Node.js packages are available using [NPM](https://www.npmjs.com/), which is the //As of SAP HANA client 2.6, connections on port 443 enable encryption by default (HANA Cloud). //encrypt: 'true', //Must be set to true when connecting to HANA as a Service - sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA, express edition instance that uses a self-signed certificate. + sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA on-premise instance that uses a self-signed certificate. //For encrypted connections, the default crypto provider is mscrypto on Windows or openSSL on Linux or macos //To use the SAP crypto provider, uncomment the below line. @@ -442,7 +442,7 @@ Asynchronous programming enables non-blocking code execution which is demonstrat //UID: 'USER1', //PWD: 'Password1', - sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA, express edition instance that uses a self-signed certificate. + sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA on-premise instance that uses a self-signed certificate. }; //Asynchronous example calling a stored procedure with callbacks @@ -500,7 +500,7 @@ Asynchronous programming enables non-blocking code execution which is demonstrat } ``` -4. Run the app. +3. Run the app. ```Shell node nodeQueryCallback.js @@ -543,7 +543,7 @@ The Node.js driver for the SAP HANA client added support for promises in the 2.1 //UID: 'USER1', //PWD: 'Password1', - sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA, express edition instance that uses a self-signed certificate. + sslValidateCertificate: 'false', //Must be set to false when connecting to an SAP HANA on-premise instance that uses a self-signed certificate. }; //Asynchronous example calling a stored procedure that uses the promise module diff --git a/tutorials/hana-clients-odbc/hana-clients-odbc.md b/tutorials/hana-clients-odbc/hana-clients-odbc.md index 62cd23f8b..e57d375ed 100644 --- a/tutorials/hana-clients-odbc/hana-clients-odbc.md +++ b/tutorials/hana-clients-odbc/hana-clients-odbc.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- @@ -58,11 +58,11 @@ The ODBC Data Source Administrator lists the installed ODBC drivers and the conf ![ODBC HANA Cloud](ODBC-HC.png) -7. Example data source configuration for SAP HANA, express edition. +7. Example data source configuration for SAP HANA on-premise instance. ![ODBC HXE](ODBC-HXE.png) - To connect to SAP HANA, express edition, **Multitenant** should be checked and the **Validate TLS/SSL certificate** option can be unchecked. For more information on this topic, see [How to Configure TLS/SSL in SAP HANA 2.0](https://blogs.sap.com/2018/11/13/how-to-configure-tlsssl-in-sap-hana-2.0/). + To connect to SAP HANA on-premise, **Multitenant** should be checked and the **Validate TLS/SSL certificate** option can be unchecked. For more information on this topic, see [How to Configure TLS/SSL in SAP HANA 2.0](https://blogs.sap.com/2018/11/13/how-to-configure-tlsssl-in-sap-hana-2.0/). 8. Click **Test connection**. @@ -118,7 +118,7 @@ The following instructions demonstrate how [unixODBC](http://www.unixodbc.org/) encrypt = true sslValidateCertificate = true - [HANA_Express] + [HANA_OnPremise] servernode = hxehost:39015 driver = /home/dan/sap/hdbclient/libodbcHDB.so databasename = HXE @@ -182,10 +182,4 @@ The following steps demonstrate how to use Microsoft Excel to query data in SAP Congratulations! You have configured an ODBC data source to contain connection information for a SAP HANA database and used that data source from Microsoft Excel. - - - - - - --- diff --git a/tutorials/hana-clients-python/hana-clients-python.md b/tutorials/hana-clients-python/hana-clients-python.md index beadc6e32..142340c06 100644 --- a/tutorials/hana-clients-python/hana-clients-python.md +++ b/tutorials/hana-clients-python/hana-clients-python.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition, programming-tool>python] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>python] primary_tag: software-product>sap-hana-cloud --- @@ -165,7 +165,7 @@ pip install hdbcli #encrypt=True, # must be set to True when connecting to HANA as a Service #As of SAP HANA Client 2.6, connections on port 443 enable encryption by default (HANA Cloud) #sslValidateCertificate=False #Must be set to false when connecting - #to an SAP HANA, express edition instance that uses a self-signed certificate. + #to an SAP HANA on-premise instance that uses a self-signed certificate. ) except dbapi.Error as er: print('Connect failed, exiting') diff --git a/tutorials/hana-clients-routing/client-version.png b/tutorials/hana-clients-routing/client-version.png new file mode 100644 index 000000000..e77156f7d Binary files /dev/null and b/tutorials/hana-clients-routing/client-version.png differ diff --git a/tutorials/hana-clients-routing/hana-clients-routing.md b/tutorials/hana-clients-routing/hana-clients-routing.md index 9d5b7a641..9ca9634a5 100644 --- a/tutorials/hana-clients-routing/hana-clients-routing.md +++ b/tutorials/hana-clients-routing/hana-clients-routing.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 30 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, tutorial>license] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, tutorial>license] primary_tag: software-product>sap-hana-cloud --- diff --git a/tutorials/hana-clients-trace/hana-clients-trace.md b/tutorials/hana-clients-trace/hana-clients-trace.md index 8d72a4cc4..13032261d 100644 --- a/tutorials/hana-clients-trace/hana-clients-trace.md +++ b/tutorials/hana-clients-trace/hana-clients-trace.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 10 -tags: [ tutorial>beginner, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition] +tags: [ tutorial>beginner, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana] primary_tag: software-product>sap-hana-cloud --- diff --git a/tutorials/hana-clients-x509/hana-clients-x509.md b/tutorials/hana-clients-x509/hana-clients-x509.md index 1073109b0..b96da77c6 100644 --- a/tutorials/hana-clients-x509/hana-clients-x509.md +++ b/tutorials/hana-clients-x509/hana-clients-x509.md @@ -4,7 +4,7 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 15 -tags: [ software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, software-product>sap-hana--express-edition, programming-tool>sql,tutorial>intermediate, topic>security] +tags: [ software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database, software-product>sap-hana, programming-tool>sql,tutorial>intermediate, topic>security] primary_tag: software-product>sap-hana-cloud --- @@ -48,7 +48,6 @@ The SAP HANA Client can use different [cryptographic service providers](https:// |macOS| LibreSSL | Yes | |macOS| SAP Cryptographic Library | Yes | - As a first step, we will ensure that basic connectivity is working with a user name and password. The steps below check the version of the SAP HANA Client, create a test user, and attempt to connect using basic authentication with mscrypto or OpenSSL. The SQL commands can be run by an admin user such as DBADMIN in the SQL console or hdbsql. 1. Check the version of SAP HANA Client on your machine and ensure it is a recent release. diff --git a/tutorials/hana-cloud-dl-clients-dot-net/hana-cloud-dl-clients-dot-net.md b/tutorials/hana-cloud-dl-clients-dot-net/hana-cloud-dl-clients-dot-net.md index ff4ec0d82..e368a3dc8 100644 --- a/tutorials/hana-cloud-dl-clients-dot-net/hana-cloud-dl-clients-dot-net.md +++ b/tutorials/hana-cloud-dl-clients-dot-net/hana-cloud-dl-clients-dot-net.md @@ -40,7 +40,7 @@ If the `dotnet` command is not recognized, it means that the .NET SDK has not be If the .NET SDK is not installed, download it from [Download .NET](https://dotnet.microsoft.com/download) and run the installer on Microsoft Windows. > Note: Select the 'Download .NET SDK x64' option. -![.NET Core SDK Install](install.png) +![.NET SDK Install](install.png) On Linux, follow the instructions for the appropriate Linux version such as [Install the .NET SDK or the .NET Runtime on openSUSE](https://docs.microsoft.com/en-us/dotnet/core/install/linux-opensuse). @@ -169,21 +169,21 @@ In order for the shell to recognize that the .NET SDK is installed and for any ` >The above app makes use of some of the data lake Relational Engine .NET driver methods, such as [SAConnection](https://help.sap.com/docs/SAP_HANA_DATA_LAKE/a894a54d84f21015b142ffe773888f8c/3c0ff5b76c5f10148352aa573b2bc242.html). Connection details for this class can be found at [Connection Properties](https://help.sap.com/docs/SAP_HANA_DATA_LAKE/a894a54d84f21015b142ffe773888f8c/9da0c496b1cc4245bae5f9cadf98e5fc.html). See also the [.NET Driver](https://help.sap.com/docs/SAP_HANA_DATA_LAKE/a895964984f210158925ce02750eb580/aa95e60108104aac808272f210f52e19.html) in the SAP HANA Cloud, data Lake client interfaces guide. Further .NET API details can be found in the [.NET API browser](https://docs.microsoft.com/en-us/dotnet/api/?view=net-6.0). -6. Run the app. +6. Run the app. ```Shell dotnet run ``` - ![Result of running the app](result.png) - + ![Result of running the app](result.png) ### Debug the application + 1. If you have not already done so, download [Visual Studio Code](https://code.visualstudio.com/Download). 2. If you have not already done so, in Visual Studio Code, choose **File | Add Folder to Workspace**, and then add the `DataLakeClientsTutorial` folder. - ![Workspace](workspace.png) + ![Explorer with the workspace opened](workspace.png) 3. Open the file `Program.cs`. @@ -199,14 +199,12 @@ In order for the shell to recognize that the .NET SDK is installed and for any ` Observe the variable values in the leftmost pane. Step through code. - ![VS Code Debugging](debugging.png) + ![Visual Studio Code Debugger](debugging.png) For further information on debugging .NET apps consult [Tutorial: Debug a .NET Core console application using Visual Studio Code](https://docs.microsoft.com/en-us/dotnet/core/tutorials/debugging-with-visual-studio-code) and [Instructions for setting up the .NET Core debugger](https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger.md). ### Knowledge check -Congratulations! You have now created and debugged a .NET application that connects to and queries an SAP HANA database. - - +Congratulations! You have now created and debugged a .NET application that connects to and queries an SAP HANA database. --- diff --git a/tutorials/hana-cloud-dl-clients-golang/hana-cloud-dl-clients-golang.md b/tutorials/hana-cloud-dl-clients-golang/hana-cloud-dl-clients-golang.md index 1d1e4583f..0129e36f1 100644 --- a/tutorials/hana-cloud-dl-clients-golang/hana-cloud-dl-clients-golang.md +++ b/tutorials/hana-cloud-dl-clients-golang/hana-cloud-dl-clients-golang.md @@ -35,9 +35,9 @@ The first step is to check if Go is installed, and if so, which version. To do s go version ``` -![go version linux](version2.png) +![Go version](version2.png) -If Go is installed, then it will return the currently installed version, such as 1.26.1 +If Go is installed, then it will return the currently installed version, such as 1.26.1. If it is not installed, download it from [Download Go](https://golang.org/dl/), run the installer, follow the provided instructions, and ensure that Go is in your path. @@ -53,19 +53,19 @@ The Go driver loads the SQLDBC library named `libdbcapiHDB` using [cgo](https:/ 1. To check if a 64-bit `gcc` compiler is installed, run the following command: - ```Shell - gcc --version - ``` + ```Shell + gcc --version + ``` On Windows (if needed), download the compiler from [MinGW](https://www.mingw-w64.org/downloads/). Under **WinLibs.com**, follow the link to [winlibs.com](https://winlibs.com/). Navigate to the **Release versions** section. Find the latest release version of the Zip archive (UCRT runtime) for Win64 – x86_64. Then extract the folder. - ![download minGW from WinLibs](winLibsMinGW.png) + ![Download minGW from WinLibs](winLibsMinGW.png) If command prompt isn't displaying the installed version after running the version check command, manually add the `bin` folder to your path by setting it in your System environment variables. >On Windows, search **Edit the System Environment Variables** and click on **Environment Variables...**. > - ![Edit Environment Variables](editEnvironmentVariables.png) + ![Edit environment variables](editEnvironmentVariables.png) Look for the `Path` environment variable within **User variables** and double click to edit. Select **Browse** and manually browse through your File Explorer to find the bin folder. Click "OK" on all environment variable windows to update. @@ -73,9 +73,9 @@ The Go driver loads the SQLDBC library named `libdbcapiHDB` using [cgo](https:/ On Windows, to ensure the gcc compiler is installed, open a new Command prompt window and run the following command: - ```Shell - gcc --version - ``` + ```Shell + gcc --version + ``` On Linux (if needed), install the System GNU C compiler for your version of Linux. Note that if you are using openSUSE, minGW is included in the installation for Go through YaST. @@ -95,7 +95,7 @@ The Go driver loads the SQLDBC library named `libdbcapiHDB` using [cgo](https:/ On Windows, search **Edit the System Environment Variables** and click on **Environment Variables**. Add a **NEW** user variable. Set the variable name to **CGO_LDFLAGS** and the value as the location of `dbcapi` library: `C:\SAP\hdlclient\bin64\dbcapi.dll` - ![Set Environment Variables](setEnvVar.png) + ![Set environment variables](setEnvVar.png) >It is also possible on Microsoft Windows to set this using the SETX command from a shell. @@ -130,7 +130,7 @@ The Go driver loads the SQLDBC library named `libdbcapiHDB` using [cgo](https:/ go mod tidy ``` - ![createModule](createModule.png) + ![Create a module](createModule.png) The contents of the data lake Client folder is not writeable so you may need to change the permissions on the driver folder or copy files to a new location. @@ -254,17 +254,17 @@ Visual Studio Code provides plugins for Go and can be used to debug an applicati 2. If you have not already done so, in Visual Studio Code, choose **File | Add Folder to Workspace**, and then add the `DataLakeClientsTutorial` folder. - ![Open Workspace](workspace.png) + ![Open workspace](workspace.png) 3. Open the file `goQuery.go`. - ![Go Extension](GoExtension.png) + ![Go extension](GoExtension.png) Visual Studio Code will recognize the `go` file extension and will suggest installing the Go for Visual Studio Code extension. Click **Install**. 4. Place a breakpoint. - ![SetBreakpoint](SetGoBreakpoint.png) + ![Set a breakpoint](SetGoBreakpoint.png) 5. Select **Run | Start Debugging**. @@ -272,7 +272,7 @@ Visual Studio Code provides plugins for Go and can be used to debug an applicati Observe the variable values in the leftmost pane. Step through the code. - ![Breakpoint](GoBreakpoint.png) + ![Stopped at a breakpoint](GoBreakpoint.png) >Note that debugging can also be performed from the command line using [Delve](https://github.com/go-delve/delve ). diff --git a/tutorials/hana-cloud-dl-clients-jdbc/hana-cloud-dl-clients-jdbc.md b/tutorials/hana-cloud-dl-clients-jdbc/hana-cloud-dl-clients-jdbc.md index 308d864e2..67b15a544 100644 --- a/tutorials/hana-cloud-dl-clients-jdbc/hana-cloud-dl-clients-jdbc.md +++ b/tutorials/hana-cloud-dl-clients-jdbc/hana-cloud-dl-clients-jdbc.md @@ -119,7 +119,8 @@ See [data lake Relational Engine JDBC driver](https://help.sap.com/docs/hana-clo ```Shell (Microsoft Windows) javac -cp %HDL_CLIENT_HOME%\Java\sajdbc4.jar;. JavaQuery.java - ``` + ``` + ```Shell (Linux) javac -cp $HDL_CLIENT_HOME/java/sajdbc4.jar:. JavaQuery.java ``` @@ -129,11 +130,12 @@ See [data lake Relational Engine JDBC driver](https://help.sap.com/docs/hana-clo ```Shell (Microsoft Windows) java -classpath %HDL_CLIENT_HOME%\Java\sajdbc4.jar;. JavaQuery ``` + ```Shell (Linux) java -classpath $HDL_CLIENT_HOME/java/sajdbc4.jar:. JavaQuery ``` - ![Java Query](jdbc-query.png) + ![Java query](jdbc-query.png) See [JDBC Program Structure](https://help.sap.com/viewer/a894a54d84f21015b142ffe773888f8c/latest/en-US/3bd5a89b6c5f1014ad1bae9e04645f43.html) for additional details. @@ -153,7 +155,7 @@ Visual Studio Code can run and debug a Java application. It is a lightweight but 4. Once the Java Extension Pack has been installed, expand the Java Project Explorer, and click on the **+** icon to add the JDBC driver as a referenced library. - ![referenced libraries](ref-libraries.png) + ![Referenced libraries](ref-libraries.png) The JDBC driver is located at `%HDL_CLIENT_HOME%\Java\sajdbc4.jar` on Microsoft Windows and `$HDL_CLIENT_HOME/java/sajdbc4.jar` on Linux. @@ -163,7 +165,7 @@ Visual Studio Code can run and debug a Java application. It is a lightweight but Notice that the program stops running at the breakpoint that was set. Step through the code by pressing F10 and observe the variable values in the variables pane. - ![VS Code Debugging](debugging.png) + ![Visual Studio Code debugging](debugging.png) ### Knowledge check diff --git a/tutorials/hana-cloud-dl-clients-node/hana-cloud-dl-clients-node.md b/tutorials/hana-cloud-dl-clients-node/hana-cloud-dl-clients-node.md index 2b9bdcf97..231c442c4 100644 --- a/tutorials/hana-cloud-dl-clients-node/hana-cloud-dl-clients-node.md +++ b/tutorials/hana-cloud-dl-clients-node/hana-cloud-dl-clients-node.md @@ -156,7 +156,7 @@ The Node.js driver covered in this tutorial is [@sap\iq-client](https://www.npmj >node nodeQuery.js >``` - > ![debug output](debug-flag.png) + > ![Debug output](debug-flag.png) > The value of the environment variable DEBUG can be seen and removed with the commands below. @@ -392,7 +392,7 @@ Visual Studio Code can run and debug a Node.js application. It is a lightweight Notice that the program stops running at the breakpoint that was set. Observe the variable values in the leftmost pane. Step through code. - ![VS Code Debugging](debugging.png) + ![Visual Studio Code debugging](debugging.png) If "Can't find Node.js binary 'node': path does not exist" error pops up, open a Shell and run the following command. diff --git a/tutorials/hana-cloud-dl-clients-odbc/hana-cloud-dl-clients-odbc.md b/tutorials/hana-cloud-dl-clients-odbc/hana-cloud-dl-clients-odbc.md index 1634ff394..1a4728d95 100644 --- a/tutorials/hana-cloud-dl-clients-odbc/hana-cloud-dl-clients-odbc.md +++ b/tutorials/hana-cloud-dl-clients-odbc/hana-cloud-dl-clients-odbc.md @@ -35,7 +35,7 @@ primary_tag: software-product-function>sap-hana-cloud--data-lake sudo zypper install unixODBC ``` - ![unixODBC install](unixODBC-install.png) + ![Installing unixODBC](unixODBC-install.png) For more details on how to accomplish this, please follow the second step of [this tutorial](hxe-ua-dbfundamentals-odbc). @@ -112,7 +112,7 @@ The ODBC Data Source Administrator can be used to view the installed ODBC driver 2. Click the **Drivers** tab and view the installed drivers. The SAP HANA Cloud, data lake Relational Engine driver is visible. - ![odbc admin drivers](drivers-1.png) + ![ODBC admin drivers](drivers-1.png) 3. Click the **User DSN** tab to view the data sources. @@ -126,7 +126,7 @@ The ODBC Data Source Administrator can be used to view the installed ODBC driver 6. Configure the data source. - ![specify the data source name](data-source1.png) + ![Specify the data source name](data-source1.png) In the **ODBC tab** of the configuration window, fill in the **Data source name**. @@ -134,15 +134,15 @@ The ODBC Data Source Administrator can be used to view the installed ODBC driver Retrieve the SQL Endpoint for your data lake instance. You can find this via the SAP BTP Cockpit or by using the **Copy SQL Endpoint** menu option in SAP HANA Cloud Central and input into **Host** field. - ![SQL Endpoint](sql-endpoint.png) + ![SQL endpoint](sql-endpoint.png) Select the **Connect to SAP HANA CLOUD, data lake Relational Engine** action. - ![specify the credentials, host and port](data-source2.png) + ![Specify the credentials, host and port](data-source2.png) 7. Verify the connection by clicking on **Test Connection** in the ODBC tab. - ![test connection](data-source4.png) + ![Test connection](data-source4.png) >If the test fails, try pressing the OK button to save the data source, then try the test again. @@ -170,15 +170,15 @@ The following steps demonstrate how to use Microsoft Excel to query data in data 4. Select **Database**, enter the credentials, and press **Connect**. - ![Credential Screen](Excel-credentials.png) + ![Credential screen](Excel-credentials.png) 5. Select a schema and table, then press **Load**. - ![Browse Schema](Excel-choose-table.png) + ![Schema selection](Excel-choose-table.png) 6. The selected data is now imported into a Microsoft Excel spreadsheet. - ![Browse Schema](Excel-result.png) + ![Hotel table data shown in Excel](Excel-result.png) > Note, if an error occurs that mentions, you do not have permission to select from SYSINDEX, a newer version of the driver may be needed. @@ -188,4 +188,4 @@ For further information on programming an application to use the ODBC client dri Congratulations! You have configured an ODBC data source to contain connection information for a SAP HANA Cloud, data lake Relational Engine database and used that data source from unixODBC and Microsoft Excel. ---- \ No newline at end of file +--- diff --git a/tutorials/hana-cloud-dl-clients-overview/feedback.png b/tutorials/hana-cloud-dl-clients-overview/feedback.png deleted file mode 100644 index 5b5341a6a..000000000 Binary files a/tutorials/hana-cloud-dl-clients-overview/feedback.png and /dev/null differ diff --git a/tutorials/hana-cloud-dl-clients-overview/hana-cloud-dl-clients-overview.md b/tutorials/hana-cloud-dl-clients-overview/hana-cloud-dl-clients-overview.md index 6977650ed..9d5f67cf6 100644 --- a/tutorials/hana-cloud-dl-clients-overview/hana-cloud-dl-clients-overview.md +++ b/tutorials/hana-cloud-dl-clients-overview/hana-cloud-dl-clients-overview.md @@ -28,10 +28,6 @@ primary_tag: software-product-function>sap-hana-cloud--data-lake This tutorial group will provide guidance on setting up an instance of [SAP HANA Cloud, data lake](https://help.sap.com/docs/hana-cloud-data-lake) so that it can then be connected to and queried using a few of the data lake client interfaces as described in [SAP HANA Cloud, Data Lake Developer Guide for Data Lake Relational Engine](https://help.sap.com/docs/hana-cloud-data-lake/developer-guide-for-data-lake-relational-engine/sap-hana-cloud-data-lake-developer-guide-for-data-lake-relational-engine) and [SAP HANA Cloud, Data Lake Client Interfaces](https://help.sap.com/docs/hana-cloud-data-lake/client-interfaces/sap-hana-cloud-data-lake-client-connections). On Microsoft Windows, in this tutorial, the shell used is the Command Prompt. -> Access help from the SAP community or provide feedback on this tutorial by navigating to the Feedback link shown below. -> ->![Give Feedback](feedback.png) - --- ### Overview of SAP HANA Cloud @@ -52,11 +48,11 @@ SAP HANA Cloud is composed of multiple components. The SAP Business Technology Platform (SAP BTP) provides multiple runtime environments such as Cloud Foundry and Kyma. When a data lake instance is created, it can be created in an SAP BTP subaccount or in a Cloud Foundry space. SAP HANA Cloud Central can be used to provision and manage instances in the SAP BTP subaccount or in a Cloud Foundry space. In the screenshot below, there is an instance of a data lake that was provisioned in the SAP BTP subaccount (Other Environments) and one that was provisioned into Cloud Foundry. -![Runtime Environments](runtime.png) +![Runtime environments](runtime.png) SAP HANA Cloud Central can be accessed (once a subscription and setup is complete) under instances and subscriptions. -![multi environment tools](multi-env-tools.png) +![Link to open SAP HANA Cloud Central](multi-env-tools.png) ### Create a data lake instance @@ -68,21 +64,21 @@ There are multiple ways to create a data lake: - A data lake can be created in step 6 of the SAP HANA Database creation wizard. - ![add a data lake](add-data-lake2.png) + ![Add a data lake](add-data-lake2.png) - A data lake can be added to an already created SAP HANA database that does not have a data lake already associated with it. - ![add data lake](add-data-lake.png) + ![Add a data lake from the instances actions menu](add-data-lake.png) When a data lake is created in either of the previous two methods, it is configured to be maximally compatible with an SAP HANA database. - A data lake can be created that is independent (standalone) of a SAP HANA database by using the **Create Instance** button. - ![independent data lake](standalone.png) + ![Create a standalone data lake](standalone.png) On the **Type** page, select the option **SAP HANA Cloud, data lake**. - ![Standalone data lake](standalone2.png) + ![Select the instanced type](standalone2.png) A standalone data lake can be configured with additional options such a collation value of UTF8BIN and blank padding set to ON to be more compatible with an on-premise SAP IQ. @@ -102,7 +98,7 @@ Perform the following steps to create a data lake Relational Engine. 4. Press the **Refresh** button or enable auto-refresh and wait for the status to change from CREATING to RUNNING. - ![data lake running](data-lake-running.png) + ![Running data lake](data-lake-running.png) >**Important:** SAP HANA Cloud, HANA data lake free tier instances are shut down overnight and will need to be restarted before working with them the next day. @@ -120,8 +116,7 @@ Once the data lake has been created, its details can be examined. After you enter your credentials, should you wish to use a different set of credentials, the current credentials can be updated using **Sign in to the Instance**. - ![Credentials](credentials2.png) - + ![Sign in with a different user](credentials2.png) ### Create tables, views, functions, and procedures @@ -129,7 +124,7 @@ In this step, a sample HOTEL dataset will be created comprising tables, a view, 1. From the action menu, select **Open SQL Console**. - ![open database explorer](open-sql-console.png) + ![Open a SQL console](open-sql-console.png) 2. Execute a few queries. @@ -140,7 +135,7 @@ In this step, a sample HOTEL dataset will be created comprising tables, a view, CALL sa_conn_properties(CONNECTION_PROPERTY('Number')); ``` - ![Query's in SQL Console](sql-console-query.png) + ![SQL queries](sql-console-query.png) Additional details can be found at [System Functions](https://help.sap.com/docs/hana-cloud-data-lake/sql-reference-for-data-lake-relational-engine/system-functions) and [Stored Procedures in Data Lake Relational Engine](https://help.sap.com/docs/hana-cloud-data-lake/sql-reference-for-data-lake-relational-engine/system-procedures-for-data-lake-relational-engine). @@ -289,7 +284,7 @@ In this step, a sample HOTEL dataset will be created comprising tables, a view, 4. Open the database objects app. Select the instance, select **Tables**, and set the schema filter to be **HOTELS** to limit the returned tables to be those that were just created in the HOTELS schema. - ![database objects app](database-objects.png) + ![Database objects app](database-objects.png) Additional details on the SQL used above can be found at [CREATE TABLE Statement for Data Lake Relational Engine](https://help.sap.com/docs/hana-cloud-data-lake/sql-reference-for-data-lake-relational-engine/create-table-statement-for-data-lake-relational-engine), [CREATE VIEW Statement for Data Lake Relational Engine](https://help.sap.com/docs/hana-cloud-data-lake/sql-reference-for-data-lake-relational-engine/create-view-statement-for-data-lake-relational-engine), and [CREATE PROCEDURE Statement for Data Lake Relational Engine](https://help.sap.com/docs/hana-cloud-data-lake/sql-reference-for-data-lake-relational-engine/create-procedure-statement-for-data-lake-relational-engine). @@ -301,13 +296,13 @@ For additional details on the SQL Console and database objects app, see the tuto The data lake client install is available without included cryptographic libraries using the SAP Developer License agreement from [SAP Development Tools](https://tools.hana.ondemand.com/#hanatools). This version does not require the user to sign in prior to downloading the software. The software will use the cryptographic library found on the OS such as OpenSSL or SAP CommonCryptoLib. Note that it currently does not include the [hdlfscli](https://help.sap.com/docs/hana-cloud-data-lake/user-guide-for-data-lake-files/hdlfscli-data-lake-files-utility) tool. -![Tools on demand](tools-on-demand.png) +![SAP development tools website](tools-on-demand.png) The data lake client install is also available from [SAP for me](https://me.sap.com/softwarecenter). This version includes cryptographic libraries and does require a login and purchase of the software to access the download. To access it, navigate to **Support Packages & Patches** | **By Alphabetical Index (A-Z)** | **H | HANA CLOUD CLIENTS | HANA CLOUD CLIENTS 1.0 | HANA DATALAKE CLIENT 1.0**. Select the platform (Microsoft Windows or Linux) and download the latest version of the archive. -![SAP for Me Download Software](sap-for-me.png) +![SAP for Me download website](sap-for-me.png) -![data lake software downloads](dl-software-downloads.png) +![HANA data lake client downloads](dl-software-downloads.png) Either location can be used with this tutorial. @@ -329,7 +324,7 @@ Ensure that [SAP JVM (Java Virtual Machine) 8.0](https://tools.hana.ondemand.com ./hdbinst ``` - ![run the installer](hdbinst.png) + ![Installer for the data lake client](hdbinst.png) 3. Configure the environment variables. This can be done by calling `hdlclienv.sh` manually or it can be added to the Bash shell by referencing it in `.bashrc`. @@ -372,29 +367,29 @@ Ensure that [SAP JVM (Java Virtual Machine) 8.0](https://tools.hana.ondemand.com 1. Run hdbsetup.exe. - ![run the installer](windows-dev-lic-installer.png) + ![Graphical installer](windows-dev-lic-installer.png) 2. Examine the installation log and take note if the required crypto libraries were located in the machine's path. - ![view log](crypto-check0.png) + ![View log](crypto-check0.png) Select View Log and search for crypto - ![crypto check](crypto-check.png) + ![Crypto check](crypto-check.png) If these libraries were not found but are on your machine perhaps as part of the [git client](https://git-scm.com/downloads/win), add that folder to your path (For example, C:\Git\mingw64\bin). 3. After the installation process is completed, open Microsoft Windows, click the **Start** icon and search for **Edit the system environment variables** and press the "Environment Variables" button under the "Advanced" tab. - ![Open Environment Variables](open-environment-var.png) + ![Open environment variables](open-environment-var.png) 4. It is also possible to run a batch file that will temporarily set the environment variables. This can be done by calling hdlclienv.bat from within a command prompt. - ![screenshot showing calling hdlclienv.bat](calling-hdlclienv.png) + ![Calling hdlclienv.bat](calling-hdlclienv.png) Then once called, the variables set can be seen by calling SET. - ![variables set](effect-of-call-bat-file.png) + ![Variables](effect-of-call-bat-file.png) 5. In the case the data lake client needs to be uninstalled, run the `hdbuninst` file located in the directory `C:\SAP\hdlclient\install`. @@ -408,7 +403,7 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h java -version ``` - ![java version](java-version.png) + ![Java version](java-version.png) If you do not have this version on Microsoft Windows, it can be downloaded and configured as shown below @@ -424,6 +419,7 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h java -version dbisql ``` + The Data Lake Relational Engine should start, this may take a moment. If the location has changed since the install was run, you may need to edit C:\SAP\hdlclient\bin64\dbisql.ini. If you do not have this version on Linux, it can be downloaded and installed as shown below. @@ -470,11 +466,11 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h 3. Provide the connection details. See below on how to obtain the instance ID and landscape values. - ![instance ID and landscape](connect-to-dl-iq.png) + ![Instance ID and landscape](connect-to-dl-iq.png) >SAP HANA Cloud Central can be used to get the instance ID and landscape value. The landscape value can be obtained from the SQL Endpoint by removing the instance ID from the start and port number from the end. - >![copy sql endpoint](dbisql-copy-endpoint.png) + >![Copy sql endpoint](dbisql-copy-endpoint.png) > > A failure to connect could be caused by the allowed connections list, which is editable in SAP HANA Cloud Central. @@ -484,7 +480,7 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h >SELECT * FROM SYS.SYSINFO; >``` > - ![DBISQL Connected](dbisql-connected.png) + ![DBISQL connected](dbisql-connected.png) >DBISQL can also be started without a GUI. > @@ -502,7 +498,6 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h >![DBISQL connected nogui](dbisql-nogui.png) - ### Insert data with Interactive SQL Client (DBISQL) 1. Execute the following insert statements to provide some sample data. @@ -621,13 +616,13 @@ The data lake client install includes [dbisql Interactive SQL Utility](https://h > >Autocommit can also be set via the connection settings dialog. > - >![autocommit setting](autocommit.png) + >![Autocommit setting](autocommit.png) > - >![autocommit setting](auto-commit-hcc.png) + >![Autocommit setting](auto-commit-hcc.png) 2. Notice that pressing ctrl-space brings up auto complete (GUI mode only). - ![auto complete](show-reservations.png) + ![Auto complete](show-reservations.png) Query a table, a view, invoke a function, and call a stored procedure. diff --git a/tutorials/hana-cloud-dl-clients-python/hana-cloud-dl-clients-python.md b/tutorials/hana-cloud-dl-clients-python/hana-cloud-dl-clients-python.md index ddc785dbb..351b822da 100644 --- a/tutorials/hana-cloud-dl-clients-python/hana-cloud-dl-clients-python.md +++ b/tutorials/hana-cloud-dl-clients-python/hana-cloud-dl-clients-python.md @@ -10,13 +10,14 @@ primary_tag: software-product-function>sap-hana-cloud--data-lake # Connect to Data Lake Relational Engine Using Python Drivers - Create and debug a Python application that connects to a data lake Relational Engine using the sqlanydb python driver or the pyodbc bridge. + Create and debug a Python application that connects to a data lake Relational Engine using the sqlanydb Python driver or the pyodbc bridge. ## Prerequisites - You have completed the first 2 tutorials in this group ## You will learn + - How to install Python, the `sqlanydb`, and `pyodbc` Python drivers - How to create, run, and debug a Python application that connects to and queries a data lake Relational Engine database @@ -45,9 +46,9 @@ The first step is to check if Python and pip are installed. If Python is not installed, it can be downloaded from [Python downloads](https://www.python.org/downloads/). - On Microsoft Windows, check the box that says **Add Python 3.x to PATH** as shown below to ensure that the interpreter will be placed in your path. The Microsoft Windows command prompt or shell will need to be reopened after Python is installed to pick up the path to python. + On Microsoft Windows, check the box that says **Add Python 3.x to PATH** as shown below to ensure that the interpreter will be placed in your path. The Microsoft Windows command prompt or shell will need to be reopened after Python is installed to pick up the path to python. - ![python-install](python-install.png) + ![Python installer](python-install.png) On OpenSUSE Tumbleweed, yast can be used to install python313. Once it has been installed its version can be seen with the below command. @@ -79,7 +80,7 @@ The first step is to check if Python and pip are installed. The `sqlanydb` package is the python driver for the data lake Relational Engine and is available as part of the data lake Relational Engine install and is available at [PyPI](https://pypi.org/project/sqlanydb/). -1. Navigate to your Data Lake Client installation folder and enter the following command to install the python driver named `sqlanydb`. +1. Navigate to your Data Lake Client installation folder and enter the following command to install the Python driver named `sqlanydb`. ```Shell (Microsoft Windows) cd %HDL_CLIENT_HOME%\SDK\Python @@ -109,7 +110,7 @@ The `sqlanydb` package is the python driver for the data lake Relational Engine A successful activation looks like this:- - ![python-install](virtualenv.png) + ![Activating a Python virtual environment(virtualenv.png) Now install the driver named 'sqlanydb'. @@ -163,11 +164,11 @@ The `sqlanydb` package is the python driver for the data lake Relational Engine 3. Save and close `pythonQuery.py`. Run the app. Make sure your data lake Relational Engine is running before executing the app. - ```Shell - python pythonQuery.py - ``` + ```Shell + python pythonQuery.py + ``` - ![python Query](sqlanydb-success.png) + ![Running pythonQuery.py](sqlanydb-success.png) For further information on the Python Driver, visit [Python and Database Access](https://help.sap.com/docs/hana-cloud-data-lake/developer-guide-for-data-lake-relational-engine/python-and-database-access). @@ -187,7 +188,6 @@ This is an alternate method of connecting to a data lake Relation Engine from a pip install pyodbc ``` - >If this command fails on Microsoft Windows with an error "Microsoft Visual C++ 14.0 is required", additional details can be found at [Unable to install pyodbc using python 3.10 in windows 10](https://stackoverflow.com/questions/69943254/unable-to-install-pyodbc-using-python-3-10-in-windows-10) and [Release python 3.10 win wheels for pyodbc](https://github.com/mkleehammer/pyodbc/issues/981). > >If this command fails on Linux, you may need to install gcc-c++, python3-devel, and unixodbc-dev. @@ -239,7 +239,7 @@ This is an alternate method of connecting to a data lake Relation Engine from a 3. The `dsn` value refers to the data source name in the Microsoft Windows ODBC Administrator or the Linux `.odbc.ini` file. - ![ODBC Administrator](odbcWindow.png) + ![ODBC administrator](odbcWindow.png) or @@ -253,7 +253,7 @@ This is an alternate method of connecting to a data lake Relation Engine from a >On some Linux distributions, python refers to a 2.x version of Python. If so, replace `python` with `python3`. - ![python Query](pyodbc-success.png) + ![Running pythonQuery.py](pyodbc-success.png) The code in `pythonQuery.py` uses [PEP 249 -- Python Database API Specification](https://www.python.org/dev/peps/pep-0249/), which defines a set of methods that provide a consistent database interface, independent of the actual database being used. @@ -269,7 +269,7 @@ Visual Studio Code provides plugins for Python and can be used to debug an appli 3. Open the file `pythonQuery.py`. - ![Python File](OpenFile.png) + ![Python file](OpenFile.png) Visual Studio Code will recognize the `py` file extension and will suggest installing the Python extension. Click **Install**. @@ -281,7 +281,7 @@ Visual Studio Code provides plugins for Python and can be used to debug an appli Observe the variable values in the leftmost pane. Step through code. - ![VS Code Debugging](debugging.png) + ![Visual Studio Code debugging](debugging.png) ### Knowledge check diff --git a/tutorials/hana-cloud-ecn/hana-cloud-ecn.md b/tutorials/hana-cloud-ecn/hana-cloud-ecn.md index 88986663a..06cd49ed0 100644 --- a/tutorials/hana-cloud-ecn/hana-cloud-ecn.md +++ b/tutorials/hana-cloud-ecn/hana-cloud-ecn.md @@ -4,25 +4,28 @@ author_name: Dan van Leeuwen author_profile: https://github.com/danielva auto_validation: true time: 45 -tags: [tutorial>intermediate, software-product-function>sap-hana-cloud--sap-hana-database,tutorial>license] +tags: software-product>sap-hana-cloud, software-product>sap-hana-cloud, software-product-function>sap-hana-cloud--sap-hana-database,tutorial>license] primary_tag: software-product>sap-hana-cloud --- # Use an Elastic Compute Node (ECN) for Scheduled Workloads + Learn about Elastic Compute Nodes (ECNs) and how they can be used to address known peaks in scheduled workloads. ## Prerequisites + - An SAP BTP account - A non trial/free tier SAP HANA Cloud instance ## You will learn + - How to create and delete an ECN - How to create a workload class and map its workload to an ECN - How to view additional details about ECNs An [Elastic Compute Node](https://help.sap.com/docs/hana-cloud-database/sap-hana-cloud-sap-hana-database-administration-guide/scale-out-using-elastic-compute-node) (ECN) can be added when it is known that additional queries will be run that take significant CPU or memory resources such as at the end of the month or quarter. Once the queries complete, the node can be removed. ECNs incur additional [costs](https://www.sap.com/about/trust-center/agreements/cloud/cloud-services.html?search=Supplement%20HANa%20Cloud&sort=latest_desc&tag=language%3Aenglish&pdf-asset=2e80541a-f07e-0010-bca6-c68f7e60039b&page=3) while running but can improve performance or could lower the total cost of ownership if their usage can reduce the instance size by covering known peak loads. In the screenshot below, if the timing of the darker blue peaks are known and are read only, an ECN node can be started and the workloads directed to the ECN enabling the overall size of the SAP HANA instance to be reduced. The [SAP HANA Cloud Capacity Unit Estimator](https://hcsizingestimator.cfapps.eu10.hana.ondemand.com/) can be used to estimate the additional cost of adding ECNs. ECNs are not available in trial or free tier. Further details on Elastic Compute Nodes can be also found at [Harnessing Dynamic Elasticity (Elastic Compute Node) for Smarter Scaling in SAP HANA Cloud](https://community.sap.com/t5/technology-blogs-by-sap/harnessing-dynamic-elasticity-elastic-compute-node-for-smarter-scaling-in/ba-p/14016836). -![workload](workload.png) +![Workload over time](workload.png) ECNs can be used to address compute intensive OLAP or read-only queries and as such, only temporary tables or replica tables can be stored on ECN instances. Queries can be routed to ECN nodes using client-side statement routing or workload classes. @@ -31,13 +34,14 @@ The following steps attempt to demonstrate an example of adding an ECN to cover --- ### Identify tasks to be run on an Elastic Compute Node (ECN) + 1. Read only CPU or memory intensive tasks that occur at a set frequency are suitable candidates to consider redirecting to an ECN. The CPU and memory used by your instance can be viewed in the usage monitor app in SAP HANA Cloud Central as shown below. - ![instance details](instance-details.png) + ![Instance details](instance-details.png) Click on the memory, compute, network, or storage cards to open the Usage Monitor app. Below, notice that the compute is spiking at a set frequency which is every morning at 7 am. - - ![Usage Monitor](usage_monitor.png) + + ![Usage monitor](usage_monitor.png) 2. The following examples are used for simulation purposes and can create a memory and CPU spike that will be moved to an ECN node. They are intended to be run on a test or trial instance and not a production instance. The size of the spike can be adjusted by increasing or decreasing the number of rows in the table. @@ -110,9 +114,9 @@ The following steps attempt to demonstrate an example of adding an ECN to cover SELECT AVG(MEMORY_USED) AS "Memory Used" FROM M_LOAD_HISTORY_HOST WHERE TIME > ADD_SECONDS(CURRENT_TIMESTAMP, -60); ``` - After calling the stored procedure CPU_SPIKE and CPU_AND_MEMORY_SPIKE, you can see that the CPU and memory usage has spiked, and you may also see an alert. Note that the metrics shown are polled once a minute, so the procedures are run multiple times. + After calling the stored procedure CPU_AND_MEMORY_SPIKE, you can see that the CPU and memory usage has spiked, and you may also see an alert. Note that the metrics shown are polled once a minute, so the procedures are run multiple times. - ![spike shown](usage_monitor_2.png) + ![CPU and memory spike](usage_monitor_2.png) The following SQL statement can also be used if expensive statement tracing is enabled. @@ -121,18 +125,19 @@ The following steps attempt to demonstrate an example of adding an ECN to cover ``` ### Create an ECN + An ECN can be created in multiple ways. Further details on the options and limitations when creating an ECN node can be found at [ECN Scope and Limitations](https://help.sap.com/docs/hana-cloud-database/sap-hana-cloud-sap-hana-database-administration-guide/ecn-scope-and-limitations). 1. Examine the options for creating an ECN. Create an ECN using one of the methods shown below. - * An ECN can be added using the manage configuration wizard in SAP HANA Cloud Central. - + - An ECN can be added using the manage configuration wizard in SAP HANA Cloud Central. + ![Add ECN](add-ecn.png) - * An ECN can be created or deleted using a CLI. The BTP CLI is shown below but the CF CLI can also be used. - - * Create a file named **ecn1.json** with the contents below which can be used to create an ECN. - + - An ECN can be created or deleted using a CLI. The BTP CLI is shown below but the CF CLI can also be used. + + - Create a file named **ecn1.json** with the contents below which can be used to create an ECN. + ```JSON { "data": { @@ -148,7 +153,7 @@ An ECN can be created in multiple ways. Further details on the options and limi } ``` - * Create a file named **no_ecn.json** with the contents below which can be used to remove the ECN. + - Create a file named **no_ecn.json** with the contents below which can be used to remove the ECN. ```JSON { @@ -159,17 +164,17 @@ An ECN can be created in multiple ways. Further details on the options and limi } ``` - * Create the ECN using the BTP CLI or CF CLI. Further details on using the CLI's can be found at [Executing SAP HANA Cloud Tasks from the Command Line](hana-cloud-automation-cli). An example using the BTP CLI is shown below. + - Create the ECN using the BTP CLI or CF CLI. Further details on using the CLI's can be found at [Executing SAP HANA Cloud Tasks from the Command Line](hana-cloud-automation-cli). An example using the BTP CLI is shown below. - ```Shell - btp login --sso - btp update services/instance --id --parameters ecn1.json - btp.exe get services/instance - ``` + ```Shell + btp login --sso + btp update services/instance --id --parameters ecn1.json + btp.exe get services/instance + ``` - * An ECN can be created using a REST API. Further details are available at [REST API for the ECN](https://help.sap.com/docs/hana-cloud-database/sap-hana-cloud-sap-hana-database-administration-guide/rest-api-for-ecn) and [Business Accelerator Hub](https://api.sap.com/api/ComputeAPI/overview). The below file is a Python notebook that illustrates the REST API. Follow the steps below if you wish to try out the REST API. - - * Create a file named `ecn_rest.ipynb`, copy the contents below into the file and open it in Visual Studio Code. + - An ECN can be created using a REST API. Further details are available at [REST API for the ECN](https://help.sap.com/docs/hana-cloud-database/sap-hana-cloud-sap-hana-database-administration-guide/rest-api-for-ecn) and [Business Accelerator Hub](https://api.sap.com/api/ComputeAPI/overview). The below file is a Python notebook that illustrates the REST API. Follow the steps below if you wish to try out the REST API. + + - Create a file named `ecn_rest.ipynb`, copy the contents below into the file and open it in Visual Studio Code. ```IPYNB { @@ -433,23 +438,23 @@ An ECN can be created in multiple ways. Further details on the options and limi } ``` - * The modification section requires values from a service key (Cloud Foundry), or a service binding (subaccount/other environment) that can be added to an SAP HANA Cloud instance. + - The modification section requires values from a service key (Cloud Foundry), or a service binding (subaccount/other environment) that can be added to an SAP HANA Cloud instance. Create a service key. - - ![service key](service-key.png) + + ![Service key](service-key.png) Copy the values from the service key into the modification section. - ![modification section](modification-section.png) + ![Modification section](modification-section.png) - * Try out the notebook by executing each cell and viewing its output. + - Try out the notebook by executing each cell and viewing its output. - ![get ECN node details](get-ecn-node-details.png) + ![ECN node details](get-ecn-node-details.png) Visual Studio Code may ask you to enter extensions related to Jupyter and Python such as the ones shown below if they are not already installed. - ![extensions](extensions.png) + ![Extensions](extensions.png) You may need to install a library such as requests if it is missing. @@ -460,21 +465,21 @@ An ECN can be created in multiple ways. Further details on the options and limi You can choose to which Python environment to run by selecting the area shown below. - ![python environments](python-env.png) - + ![Python environments](python-env.png) + 2. Once the ECN has been created, its details can be viewed. - * In the instances view. - + - In the instances view. + ![ECN created](added-ecn.png) - - * In an instances detail pane. + + - In an instances detail pane. ![ECN details page](added-ecn-details.png) Note that the status is also shown. - * Through SQL + - Through SQL ```SQL SELECT HOST, PORT FROM M_SERVICES WHERE SERVICE_NAME = 'computeserver'; @@ -485,14 +490,16 @@ An ECN can be created in multiple ways. Further details on the options and limi ![ECN host and port](ecn1.png) ### Create a workload class + Workload classes can be used to direct a specified workload to an ECN. Further details on workload classes can be found at [Workload Management](https://help.sap.com/docs/HANA_CLOUD_DATABASE/f9c5015e72e04fffa14d7d4f7267d897/workload-management). 1. Create a workload class. - ```SQL + ```SQL CREATE WORKLOAD CLASS "WLC1"; ``` -2. Route the an ECN. + +2. Route the an ECN. The workload class can set a routing hint to the ECN. @@ -500,31 +507,31 @@ Workload classes can be used to direct a specified workload to an ECN. Further ALTER WORKLOAD CLASS "WLC1" SET 'ROUTING LOCATION HINT' = 'ecn1'; ``` -* This can also be accomplished in the workload management app as shown below. + - This can also be accomplished in the workload management app as shown below. - ![Workload management app](routing-ui-1.png) + ![Workload management app](routing-ui-1.png) - After clicking on the routing location, the ECN node ecn1 can be selected. + After clicking on the routing location, the ECN node ecn1 can be selected. - ![Select the routing location](routing-ui-2.png) + ![Select the routing location](routing-ui-2.png) 3. Map a workload to the workload class. - * A mapping to a user can be added + - A mapping to a user can be added ```SQL CREATE WORKLOAD MAPPING "WLM1" WORKLOAD CLASS "WLC1" SET 'USER NAME' = 'USER4'; --DROP WORKLOAD MAPPING "WLM1"; ``` - * A mapping can be made to specific objects + - A mapping can be made to specific objects ```SQL CREATE WORKLOAD MAPPING "WLM2" WORKLOAD CLASS "WLC1" SET 'SCHEMA NAME' = 'USER4', 'OBJECT NAME' = 'CPU_SPIKE'; CREATE WORKLOAD MAPPING "WLM3" WORKLOAD CLASS "WLC1" SET 'SCHEMA NAME' = 'USER4', 'OBJECT NAME' = 'CPU_AND_MEMORY_SPIKE'; ``` - * A mapping can be made to a session variable + - A mapping can be made to a session variable ```SQL CREATE WORKLOAD MAPPING "WLM4" WORKLOAD CLASS "WLC1" SET 'APPLICATION COMPONENT NAME' = 'ECN_APP'; @@ -551,7 +558,7 @@ Workload classes can be used to direct a specified workload to an ECN. Further SELECT * FROM WORKLOAD_MAPPINGS; ``` - ![workload class details](mappings.png) + ![Workload class details](mappings.png) 5. Run the query again and verify that the query was run on the ECN node. @@ -579,6 +586,7 @@ Workload classes can be used to direct a specified workload to an ECN. Further It may also be of interest to compare the execution time between this run and after the table is replicated onto the ECN node in a subsequent step. ### Route to ECN with a hint + An alternate approach without using a workload class is to use a hint. 1. Execute the below SQL. @@ -596,9 +604,10 @@ An alternate approach without using a workload class is to use a hint. ORDER BY LAST_EXECUTION_TIMESTAMP DESC; ``` - ![using a hint](hint.png) + ![Using a hint](hint.png) ### Replicate a table to the ECN + A replica table can be stored on an ECN. This may lead to lower resource consumption on the coordinator and reduced latency. For additional details see [Advantages and Disadvantages of Table Replication](https://help.sap.com/docs/hana-cloud-database/sap-hana-cloud-sap-hana-database-administration-guide/advantages-and-disadvantages-of-table-replication). The following steps demonstrate replicating a table to the ECN and using it in a query. 1. Run the below in the SQL Console after replacing the host name with the value from the previous query against the M_VOLUMES table view. @@ -616,7 +625,7 @@ A replica table can be stored on an ECN. This may lead to lower resource consum SELECT * FROM M_TABLE_REPLICAS; ``` - ![replica table](ecn_ex2a.png) + ![Replica table](ecn_ex2a.png) Run the below SQL to indicate that the workload class should use async replica tables. @@ -643,6 +652,7 @@ A replica table can be stored on an ECN. This may lead to lower resource consum Notice that this time the table is also located on the ECN. ### Remove the workload class and ECN + Before removing the ECN node, disable the workload class so that new queries are no longer directed to the ECN node. 1. Execute the below SQL @@ -657,7 +667,7 @@ Before removing the ECN node, disable the workload class so that new queries are ALTER SYSTEM ALTER CONFIGURATION ('global.ini', 'DATABASE') SET ('distribution', 'force_reroute') = 'FALSE' WITH RECONFIGURE; SELECT * FROM SYS.M_CONFIGURATION_PARAMETER_VALUES WHERE SECTION = 'distribution'; ``` - + 2. Remove the ECN. ```SHELL @@ -666,11 +676,12 @@ Before removing the ECN node, disable the workload class so that new queries are ``` ### Node.js app demonstrating prepared statements and the option routeDirectExecute on statement routing + The below Node.js app is used to demonstrate that statements must be prepared first to be routed to an ECN as documented at [Statement Routing](https://help.sap.com/docs/SAP_HANA_CLIENT/f1b440ded6144a54ada97ff95dac7adf/077d30cc847443288d3f0574356de4e7.html). Some tools such as the SQL Console in SAP HANA Cloud Central, the SAP HANA database explorer, and [hdbsql](https://help.sap.com/docs/SAP_HANA_CLIENT/f1b440ded6144a54ada97ff95dac7adf/c24d054bbb571014b253ac5d6943b5bd.html) by default, always prepare statements. -![prepare before execute](prepare-before-execute.png) +![Prepare before execute](prepare-before-execute.png) The below code when run, will not be executed on the ECN, unless the variable prepare is set to true or the [routeDirectExecute](https://help.sap.com/docs/SAP_HANA_CLIENT/f1b440ded6144a54ada97ff95dac7adf/4fe9978ebac44f35b9369ef5a4a26f4c.html) option is set to true. @@ -731,19 +742,20 @@ Further details on creating applications that connect to an SAP HANA Cloud datab Output when the variable prepare is false. - ![prepare is false](no-prepare.png) - + ![Prepare is false](no-prepare.png) + Output when the variable prepare is true. - ![prepare is true](prepare.png) + ![Prepare is true](prepare.png) Output when the variable prepare is false but routeDirectExecute is true. - ![routedirectexecute](route-direct-execute.png) + ![routedirectexecute is true](route-direct-execute.png) For further details on the methods of the connection class used above consult [prepare](https://help.sap.com/docs/SAP_HANA_CLIENT/f1b440ded6144a54ada97ff95dac7adf/c63d283b3635469bb8afbefbbe7aea7b.html) and [execute](https://help.sap.com/docs/SAP_HANA_CLIENT/f1b440ded6144a54ada97ff95dac7adf/ef5564058b1747ce99fd3d1e03266b39.html). ### Procedure to check if the ECN is started + The following procedure can be used to check if the ECN is available and then when it is to run a workload. 1. Execute the below SQL @@ -756,21 +768,22 @@ The following procedure can be used to check if the ECN is available and then wh BEGIN USING SQLSCRIPT_PRINT AS PRTLIB; USING SQLSCRIPT_SYNC AS SYNCLIB; - --Check if the ECN is running, pause if not - DECLARE state STRING := ''; - SELECT TOP 1 SERVICE_ACTIVE INTO state DEFAULT NULL FROM M_SYSTEM_AVAILABILITY WHERE HOST LIKE '%-ern-%' ORDER BY EVENT_TIME DESC; - PRTLIB:PRINT_LINE(state); - WHILE :state != 'YES' DO - CALL SYNCLIB:SLEEP_SECONDS(10); - SELECT TOP 1 SERVICE_ACTIVE INTO state DEFAULT NULL FROM M_SYSTEM_AVAILABILITY WHERE HOST LIKE '%-ern-%' ORDER BY EVENT_TIME DESC; - PRTLIB:PRINT_LINE(state); - END WHILE; + --Check if the ECN is running, pause if not + DECLARE state STRING := ''; + SELECT TOP 1 SERVICE_ACTIVE INTO state DEFAULT NULL FROM M_SYSTEM_AVAILABILITY WHERE HOST LIKE '%-ern-%' ORDER BY EVENT_TIME DESC; + PRTLIB:PRINT_LINE(state); + WHILE :state != 'YES' DO + CALL SYNCLIB:SLEEP_SECONDS(10); + SELECT TOP 1 SERVICE_ACTIVE INTO state DEFAULT NULL FROM M_SYSTEM_AVAILABILITY WHERE HOST LIKE '%-ern-%' ORDER BY EVENT_TIME DESC; + PRTLIB:PRINT_LINE(state); + END WHILE; END; CALL WAIT_FOR_ECN(); CALL CPU_AND_MEMORY_SPIKE(); ``` ### ECN sample script + The following steps demonstrate an approach to automating the creation, running a workload, and deletion of an ECN. 1. Create a file named **ecn_workload.sql**. @@ -796,11 +809,12 @@ The following steps demonstrate an approach to automating the creation, running Instructions on using hdbsql and setting the user key can be found at [Executing SQL Statements from a shell](hana-cloud-automation-cli). ### Use SAP Automation Pilot to schedule the provisioning of an ECN -The SAP Automation Pilot can be used to perform and schedule operations on services running in the SAP BTP. The tutorial [Automating SAP HANA Cloud Tasks with the SAP Automation Pilot Service](https://developers.sap.com/tutorials/hana-cloud-automation-pilot.html) can be used to started with the SAP Automation Pilot. The following step demonstrates how commands can be scheduled which will start and stop an ECN node and also execute SQL to enable or disable a workload class. + +The SAP Automation Pilot can be used to perform and schedule operations on services running in the SAP BTP. The tutorial [Automating SAP HANA Cloud Tasks with the SAP Automation Pilot Service](https://developers.sap.com/tutorials/hana-cloud-automation-pilot.html) can be used to started with the SAP Automation Pilot. The following step demonstrates how commands can be scheduled which will start and stop an ECN node and also execute SQL to enable or disable a workload class. 1. Import the catalog below into the SAP Automation Pilot. - ![import catalog](import.png) + ![Import catalog](import.png) ```JSON { @@ -920,7 +934,7 @@ The SAP Automation Pilot can be used to perform and schedule operations on servi } }, "values": { - "service-manager-binding": "{\n \"clientid\": \"sb-a6bfefa2-5ce6-46b5-ad3f-5e2e5801a395!b7113|service-manager!b16\",\n \"clientsecret\": \"ab2f6ae1-34b3-4b0a-ba84-dfc397675edf$9uEmOt958OsnHnY_mVvNSZHRntaoLVgLgMmf5ZBOEkw=\",\n \"url\": \"https://dan-van-leeuwen.authentication.ca10.hana.ondemand.com\",\n \"xsappname\": \"a6bfefa2-5ce6-46b5-ad3f-5e2e5801a395!b7113|service-manager!b16\",\n \"sm_url\": \"https://service-manager.cfapps.ca10.hana.ondemand.com\"\n}", + "service-manager-binding": "{\n \"clientid\": \"sb-a6bfefa2-...\",\n \"clientsecret\": \"ab2f6ae1-...\",\n \"url\": \"https://dan-van-leeuwen.authentication.ca10.hana.ondemand.com\",\n \"xsappname\": \"a6bfefa2-5ce6-46b5-ad3f-5e2e5801a395!b7113|service-manager!b16\",\n \"sm_url\": \"https://service-manager.cfapps.ca10.hana.ondemand.com\"\n}", "cf-password": "", "db-password": "" }, @@ -1476,11 +1490,11 @@ The SAP Automation Pilot can be used to perform and schedule operations on servi 2. The catalog will appear under My Catalogs and is named Elastic Compute Node Provisioning - ![catalog imported](imported.png) + ![Catalog imported](imported.png) 3. Examine the imported commands and inputs. The list of commands are shown below. Notice that there is a set of commands for SAP HANA Cloud instances provisioned to the Cloud Foundry environment and another set for instances provisioned to a subaccount. - ![commands](commands.png) + ![Commands](commands.png) The two inputs are shown below. They provide a location where the details are specified to update the SAP HANA Cloud database instance. Credentials are needed for a Cloud Foundry user that has permissions to update the SAP HANA Cloud database instance and for a SQL user that can enable or disable a workload class and run SQL queries in the database. @@ -1489,55 +1503,55 @@ The SAP Automation Pilot can be used to perform and schedule operations on servi A separate input named NonSensitive was created so that the input values that are not specified as sensitive can be displayed in the execution viewer. - ![input](input.png) + ![Input](input.png) 4. Open the inputs and edit their values to match the SAP HANA Cloud instance that you wish to work with. - ![edit input values](edit-input.png) + ![Edit input values](edit-input.png) 5. Open the CFAddECN command. Notice that it takes NonSensitive and Sensitive inputs as an additional value to the input. - ![additional value](addecn-input.png) + ![Additional value](addecn-input.png) It contains a test executor that can be used to optionally perform an additional check such as checking the memory or CPU use. - ![add check](add-check.png) + ![Add check](add-check.png) The addECN and enableWorkloadClass executors check the output of the test executor to see if they should run or not. - ![check condition](check-condition.png) + ![Check condition](check-condition.png) The addECN executor uses the built in command cf-sapcp:UpdateCfServiceInstance that will request the ECN node to be created. Notice that the parameter values are being set using the inputs. - ![add ECN executor](add-ecn-executor.png) - + ![Add ECN executor](add-ecn-executor.png) + The enableWorkloadClass executor executes a SQL statement to enable a workload class which is used to direct a workload to the just started ECN node. - ![enable workload class](enable-workload-class.png) + ![Enable workload class](enable-workload-class.png) 6. Open the CFDeleteECN command. Notice that a test can also be performed before the ECN is deleted. Depending on your workloads, you may wish to increase this delay or add a more involved check. - ![wait added before delete ECN](delete-ecn-executor.png) + ![Wait added before delete ECN](delete-ecn-executor.png) 7. Try out the commands by pressing the Trigger button. - ![trigger AddECN](trigger.png) + ![Trigger AddECN](trigger.png) Under Additional Features, select Execution Log to see details on the test condition. - ![enable execution log](enable-execution-log.png) + ![Enable execution log](enable-execution-log.png) The non sensitive input values can be seen as shown below. - ![Step Input](step-input.png) + ![Step input](step-input.png) The test condition check result can be seen in the step logs. - ![condition check](step-logs.png) + ![Condition check](step-logs.png) 8. The status of the execution can be seen in the Executions section. - ![executed](executed.png) + ![Executed](executed.png) If your SAP HANA Cloud instance has an allow list configured, add the IP from [IPs for requests from SAP Automation Pilot](https://help.sap.com/docs/automation-pilot/automation-pilot/what-is-sap-automation-pilot?version=Cloud). @@ -1548,30 +1562,31 @@ The SAP Automation Pilot can be used to perform and schedule operations on servi ![Schedule](schedule.png) ### ECN advisor + SAP HANA Cloud Central includes an ECN advisor that provides recommendations for workloads that may be applicable to be run on an ECN. -![advisor card](advisors-card.png) +![Advisor card](advisors-card.png) -![enable advisor](enable-advisor.png) +![Enable advisor](enable-advisor.png) -![set the threshold](thresholds.png) +![Set the threshold](thresholds.png) -![recommendation](ecn-advisor-recommendation.png) +![Recommendation](ecn-advisor-recommendation.png) There are a few requirements with the advisor: - -* The instance must have 5 vCPUs -* A workload class is required +- The instance must have 5 vCPUs -* The timeframe duration must not exceed 24 hours +- A workload class is required -* The timeframe cannot be less than 30 minutes. +- The timeframe duration must not exceed 24 hours -* The timeframe must be within the last 14 days +- The timeframe cannot be less than 30 minutes. -* The timeframe must be 20 minutes later than the current timestamp. +- The timeframe must be within the last 14 days +- The timeframe must be 20 minutes later than the current timestamp. ### Knowledge check + You have now explored Elastic Compute Nodes and how they can be used to address peaks in scheduled workloads. diff --git a/tutorials/hana-cloud-sqltools-remote-sources/hana-cloud-sqltools-remote-sources.md b/tutorials/hana-cloud-sqltools-remote-sources/hana-cloud-sqltools-remote-sources.md index 6d8edf8c1..15af1628d 100644 --- a/tutorials/hana-cloud-sqltools-remote-sources/hana-cloud-sqltools-remote-sources.md +++ b/tutorials/hana-cloud-sqltools-remote-sources/hana-cloud-sqltools-remote-sources.md @@ -34,7 +34,7 @@ For additional details on SAP HANA smart data access (SDA) and SAP HANA Smart Da >The SAP HANA Cloud free tier is limited to creating one SAP HANA database and one data lake instance. -The example in step 1 demonstrates a connection from one SAP HANA Cloud, SAP HANA database to another. The example in step 2 demonstrates a connection from an SAP HANA Cloud, SAP HANA database to an SAP HANA Cloud, data lake Relational Engine. The example in step 3 demonstrates connecting from SAP HANA Cloud, data lake Relational Engine to an SAP HANA Cloud, SAP HANA database. The example in step 4 demonstrates connecting from one SAP HANA Cloud, data lake Relational Engine to another. +The example in step 1 demonstrates a connection from one SAP HANA Cloud, SAP HANA database to another. The example in step 2 demonstrates a connection from an SAP HANA Cloud, SAP HANA database to an SAP HANA Cloud, data lake Relational Engine. The example in step 3 demonstrates connecting from SAP HANA Cloud, data lake Relational Engine to an SAP HANA Cloud, SAP HANA database. The example in step 4 demonstrates connecting from one SAP HANA Cloud, data lake Relational Engine to another. It is also possible to connect from an SAP HANA on-premise database to SAP HANA Cloud or from SAP HANA Cloud to an on-premise SAP HANA database. These last two examples are covered at [Access Remote Sources with SAP HANA Database Explorer](tutorials.hana-dbx-remote-sources). --- diff --git a/tutorials/hana-dbx-remote-sources/hana-dbx-remote-sources.md b/tutorials/hana-dbx-remote-sources/hana-dbx-remote-sources.md index 0a3848176..716bd98a7 100644 --- a/tutorials/hana-dbx-remote-sources/hana-dbx-remote-sources.md +++ b/tutorials/hana-dbx-remote-sources/hana-dbx-remote-sources.md @@ -35,7 +35,7 @@ For additional details on SAP HANA smart data access (SDA) and SAP HANA Smart Da >The SAP HANA Cloud free tier or trial is limited to creating one SAP HANA database and one data lake instance. -The example in step 1 demonstrates connectivity from an on-premise, SAP HANA, express edition database to an SAP HANA Cloud, SAP HANA  database. The example in step 2 demonstrates a connection from an SAP HANA Cloud, SAP HANA  database to an SAP HANA Cloud, data lake Relational Engine. The example in step 3 demonstrates connecting from SAP HANA Cloud, data lake Relational Engine to an SAP HANA Cloud, SAP HANA  database. The example in step 4 demonstrates connecting from one SAP HANA Cloud, data lake Relational Engine to another. The example in step 5 demonstrates connecting from SAP HANA Cloud, database via the Cloud Connector to an SAP HANA, express edition database. +The example in step 1 demonstrates connectivity from an on-premise, SAP HANA database to an SAP HANA Cloud, SAP HANA  database. The example in step 2 demonstrates a connection from an SAP HANA Cloud, SAP HANA  database to an SAP HANA Cloud, data lake Relational Engine. The example in step 3 demonstrates connecting from SAP HANA Cloud, data lake Relational Engine to an SAP HANA Cloud, SAP HANA  database. The example in step 4 demonstrates connecting from one SAP HANA Cloud, data lake Relational Engine to another. The example in step 5 demonstrates connecting from SAP HANA Cloud, database via the Cloud Connector to an SAP HANA, express edition database. --- @@ -434,6 +434,8 @@ The [Cloud Connector](https://help.sap.com/docs/connectivity/sap-btp-connectivit ![Enable the Cloud Connector](enable-cloud-connector.png) + This also requires adding the hana-cloud-option service plan instance. Details to enable this are provided at [SAP Note: 3751673 - SAP HANA Cloud Connector Requires `hana-cloud-option` Subscription](https://me.sap.com/notes/3751673). + 2. [Download the Cloud Connector](https://tools.hana.ondemand.com/#cloud). The software needs to run on a machine that can access your on-premise SAP HANA instance. In this example, the Cloud Connector is running on Windows and is accessing an SAP HANA, express edition database running in a VM on the same machine. 3. As described at [Installation on Microsoft Windows OS](https://help.sap.com/docs/connectivity/sap-btp-connectivity-cf/installation-on-microsoft-windows-os?version=Cloud), a Java JDK is required.