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

# SAP HANA

> Connect an SAP HANA database to Genloop with host, port, schema, and read-only credentials over an encrypted connection.

Genloop connects to SAP HANA over an encrypted connection using a read-only user. You provide the schema Genloop should read.

## Before you connect

* An SAP HANA user with read access to the schema you want to query.
* The **schema** name that holds your tables.
* Network access from Genloop. If the server is behind a firewall, allow Genloop's regional IP address. See [Before you begin](/using-genloop/connections/connect-a-database#before-you-begin).

## Connection fields

| Field               | Description                                                           |
| ------------------- | --------------------------------------------------------------------- |
| **Connection name** | A name to identify this connection in Genloop                         |
| **Host**            | Server hostname, for example `xxxxx.hanacloudservices.com`            |
| **Port**            | The port your server listens on. Defaults to `443` for SAP HANA Cloud |
| **Schema**          | Schema Genloop reads, for example `DBADMIN`                           |
| **Username**        | SAP HANA user Genloop connects as                                     |
| **Password**        | Password for that user                                                |

## Encryption and network

The connection is always encrypted and the server's certificate is validated; there is no setting to change this. An SSH tunnel is not used, so make sure Genloop can reach the server directly.

## Permissions

Genloop only reads your data and never writes to your database. You can connect with any user that already has read access to the schema you select.

If you want a dedicated read-only user for Genloop, ask your database administrator to set one up.

<Accordion title="Minimal read-only grant (for your database administrator)">
  Run this in your SAP HANA database:

  ```sql theme={null}
  GRANT SELECT ON SCHEMA YOUR_SCHEMA TO GENLOOP_USER;
  ```
</Accordion>

## Next steps

<CardGroup cols={2}>
  <Card title="Connect a database" icon="database" href="/using-genloop/connections/connect-a-database">
    Back to the full connection flow.
  </Card>

  <Card title="Context Hub" icon="brain" href="/using-genloop/context-hub">
    View and edit the memory built from your connection.
  </Card>
</CardGroup>
