Connect to and manage SAP HANA in Microsoft Purview
This article outlines how to register SAP HANA, and how to authenticate and interact with SAP HANA in Microsoft Purview. For more information about Microsoft Purview, read the introductory article.
Supported capabilities
Metadata Extraction | Full Scan | Incremental Scan | Scoped Scan | Classification | Labeling | Access Policy | Lineage | Data Sharing | Live view |
---|---|---|---|---|---|---|---|---|---|
Yes | Yes | No | Yes | No | No | No | No | No | No |
When scanning SAP HANA source, Microsoft Purview supports extracting technical metadata including:
- Server
- Databases
- Schemas
- Tables including the columns, foreign keys, indexes, and unique constraints
- Views including the columns. Note SAP HANA Calculation Views are not supported now.
- Stored procedures including the parameter dataset and result set
- Functions including the parameter dataset
- Sequences
- Synonyms
When setting up scan, you can choose to scan an entire SAP HANA database, or scope the scan to a subset of schemas matching the given name(s) or name pattern(s).
Known limitations
When object is deleted from the data source, currently the subsequent scan won't automatically remove the corresponding asset in Microsoft Purview.
Prerequisites
You must have an Azure account with an active subscription. Create an account for free.
You must have an active Microsoft Purview account.
You need Data Source Administrator and Data Reader permissions to register a source and manage it in the Microsoft Purview governance portal. For more information about permissions, see Access control in Microsoft Purview.
Set up the right integration runtime for your scenario:
- To use a self-hosted integration runtime:
- Follow the article to create and configure a self-hosted integration runtime.
- Ensure JDK 11 is installed on the machine where the self-hosted integration runtime is installed. Restart the machine after you newly install the JDK for it to take effect.
- Ensure that Visual C++ Redistributable (version Visual Studio 2012 Update 4 or newer) is installed on the machine where the self-hosted integration runtime is running. If you don't have this update installed, download it now.
- Download the SAP HANA JDBC driver (JAR ngdbc) on the machine where your self-hosted integration runtime is running. Note down the folder path which you will use to set up the scan.
- To use a kubernetes supported self-hosted integration runtime:
- Follow the article to create and configure a kubernetes supported integration runtime.
- Download the SAP HANA JDBC driver (JAR ngdbc) on the machine where your self-hosted integration runtime is running. Note down the folder path which you will use to set up the scan.
Note
The driver should be accessible by the self-hosted integration runtime. By default, self-hosted integration runtime uses local service account "NT SERVICE\DIAHostService". Make sure it has "Read and execute" and "List folder contents" permission to the driver folder.
- To use a self-hosted integration runtime:
Required permissions for scan
Microsoft Purview supports basic authentication (username and password) for scanning SAP HANA.
The SAP HANA user you specified must have the permission to select metadata of the schemas you want to import.
CREATE USER <user> PASSWORD <password> NO FORCE_FIRST_PASSWORD_CHANGE;
GRANT SELECT METADATA ON SCHEMA <schema1> TO <user>;
GRANT SELECT METADATA ON SCHEMA <schema2> TO <user>;
And the user must have the permission to select on system table _SYS_REPO.ACTIVE_OBJECT and on system schemas _SYS_BI and _SYS_BIC.
GRANT SELECT ON _SYS_REPO.ACTIVE_OBJECT TO <user>;
GRANT SELECT ON SCHEMA _SYS_BI TO <user>;
GRANT SELECT ON SCHEMA _SYS_BIC TO <user>;
Register
This section describes how to register an SAP HANA in Microsoft Purview by using the Microsoft Purview governance portal.
Open the Microsoft Purview governance portal by:
- Browsing directly to https://web.purview.azure.com and selecting your Microsoft Purview account.
- Opening the Azure portal, searching for and selecting the Microsoft Purview account. Selecting the the Microsoft Purview governance portal button.
Select Data Map on the left pane.
Select Register.
In Register sources, select SAP HANA > Continue.
On the Register sources (SAP HANA) screen, do the following:
For Name, enter a name that Microsoft Purview will list as the data source.
For Server, enter the host name or IP address used to connect to an SAP HANA source. For example,
MyDatabaseServer.com
or192.169.1.2
.For Port, enter the port number used to connect to the database server (39013 by default for SAP HANA).
Select a collection from the list.
Select Finish.
Scan
Use the following steps to scan SAP HANA databases to automatically identify assets. For more information about scanning in general, see Scans and ingestion in Microsoft Purview.
Authentication for a scan
The supported authentication type for an SAP HANA source is Basic authentication.
Create and run scan
In the Management Center, select integration runtimes. Make sure that a self-hosted integration runtime is set up. If it isn't set up, use the steps in in prerequisites.
Go to Sources.
Select the registered SAP HANA source.
Select + New scan.
Provide the following details:
Name: Enter a name for the scan.
Connect via integration runtime: Select the configured self-hosted integration runtime.
Credential: Select the credential to connect to your data source. Make sure to:
- Select Basic Authentication while creating a credential.
- Provide the user name used to connect to the database server in the User name input field.
- Store the user password used to connect to the database server in the secret key.
For more information, see Credentials for source authentication in Microsoft Purview.
Database: Specify the name of the database instance to import.
Schema: List subset of schemas to import expressed as a semicolon separated list. For example,
schema1; schema2
. All user schemas are imported if that list is empty. All system schemas and objects are ignored by default.Acceptable schema name patterns that use SQL
LIKE
expression syntax include the percent sign (%). For example,A%; %B; %C%; D
means:- Start with A or
- End with B or
- Contain C or
- Equal D
Usage of NOT and special characters aren't acceptable.
Driver location: Specify the path to the JDBC driver location in your machine where self-host integration runtime is running. For example:
D:\Drivers\SAPHANA
.- For self-hosted integration runtime on a local machine:
D:\Drivers\SAPHANA
. It's the path to valid JAR folder location. The value must be a valid absolute file path and doesn't contain space. Make sure the driver is accessible by the self-hosted integration runtime;; learn more from prerequisites section. - For Kubernetes-supported self-hosted integration runtime:
./drivers/SAPHANA
. It's the path to valid JAR folder location. The value must be a valid relative file path. Please refer to the documentation to set up a scan with external drivers for uploading drivers in advance.
- For self-hosted integration runtime on a local machine:
Maximum memory available: Maximum memory (in gigabytes) available on the customer's machine for the scanning processes to use. This value is dependent on the size of SAP HANA database to be scanned.
Select Continue.
For Scan trigger, choose whether to set up a schedule or run the scan once.
Review your scan and select Save and Run.
View your scans and scan runs
To view existing scans:
- Go to the Microsoft Purview portal. On the left pane, select Data map.
- Select the data source. You can view a list of existing scans on that data source under Recent scans, or you can view all scans on the Scans tab.
- Select the scan that has results you want to view. The pane shows you all the previous scan runs, along with the status and metrics for each scan run.
- Select the run ID to check the scan run details.
Manage your scans
To edit, cancel, or delete a scan:
Go to the Microsoft Purview portal. On the left pane, select Data Map.
Select the data source. You can view a list of existing scans on that data source under Recent scans, or you can view all scans on the Scans tab.
Select the scan that you want to manage. You can then:
- Edit the scan by selecting Edit scan.
- Cancel an in-progress scan by selecting Cancel scan run.
- Delete your scan by selecting Delete scan.
Note
- Deleting your scan does not delete catalog assets created from previous scans.
Next steps
Now that you've registered your source, use the following guides to learn more about Microsoft Purview and your data: