> ## Documentation Index
> Fetch the complete documentation index at: https://docs.less.tech/llms.txt
> Use this file to discover all available pages before exploring further.

# SAP HANA

> [!NOTE]
>
> Allow the Less IPs to reach your SAP HANA system. You can find the IPs [here](https://docs.less.tech/guides/less-ip.md).

The SAP HANA source extracts tables and views from SAP HANA Cloud or an on-premise SAP HANA database.

Use a database user that can `SELECT` the schemas you want to extract. The table list only includes objects that user is allowed to see.

### Setup

There are four steps: Account, Credentials, SSH, and Tables.

**1. Account**

Choose **SAP HANA Cloud** or **On-premise**.

SAP HANA Cloud uses port **443** and always connects with TLS. Copy the host from the SAP BTP cockpit. It looks like `example.hana.prod-eu10.hanacloud.ondemand.com`.

An on-premise system usually uses port **3NN15**, where NN is the instance number. Instance 00 is port **30015**. Turn on **Encrypt connection** when the database requires TLS. Turn off **Validate TLS certificate** only when the server certificate is not signed by a public authority.

**Schema** is optional. When you set it, the table list is limited to that schema. Custom queries can still read other schemas the user can access.

**2. Credentials**

Enter the database **username** and **password**.

**3. SSH**

Connect directly when Less can reach the host. Use an SSH tunnel when the database is only reachable through a bastion host.

Enter the **SSH host**, **SSH port**, **SSH username**, and **SSH password**. You can upload a private key instead of using a password.

**4. Tables**

Click **Connect** to load the schemas and tables. The message shown is the message returned by SAP HANA.

After the connection succeeds, select the **tables** to extract, or switch to **Query-based** and write one or more SQL statements. Each query needs a name, which becomes the table name in Less.

> [!WARNING]
>
> You can select either tables or custom queries. You cannot select both.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.