Skip to main content
Glama
SAP HANA MCP Server

SAP HANA MCP Server

HANA MCP Server — Distribución cliente

Paquete ejecutable del Model Context Protocol (MCP) server para SAP HANA y SAP Business One Service Layer.

📥 Descarga

Descargá la última versión desde Releases:

  • hana-mcp-server-v0.3.1-win-x64.zip

Descomprimí el ZIP en una carpeta permanente, por ejemplo:

C:\hana-mcp-client\

Related MCP server: SAP Datasphere MCP Server

✅ Requisitos

  • Windows 10/11 o Windows Server 2019+ (x64)

  • Acceso de red al servidor SAP HANA

  • Token de licencia JWT proporcionado por el vendor (si aplica)

No necesitás instalar Node.js: el ejecutable incluye su propio runtime.

🚀 Instalación rápida

  1. Descomprimí el ZIP en la carpeta destino.

  2. Copiá .env.example como .env y completá al menos:

    • HANA_HOST

    • HANA_PORT

    • HANA_USER

    • HANA_PASSWORD

    • HANA_SCHEMA

  3. Si recibiste el token JWT como archivo, guardalo como .hana-license en la misma carpeta.

  4. Ejecutá start.bat (doble clic) o configurá tu cliente MCP para que apunte a hana-mcp-server.exe.

⚙️ Configuración de .env

Ejemplo mínimo:

HANA_HOST=tu-servidor-hana
HANA_PORT=30015
HANA_USER=TU_USUARIO
HANA_PASSWORD=TU_PASSWORD
HANA_SCHEMA=TU_SCHEMA
HANA_SSL=false
HANA_VALIDATE_CERT=false

Ver .env.example para todas las opciones disponibles.

🔐 Licenciamiento

Obtené tu hardware ID ejecutando el servidor y consultando la tool hana_show_license_info. Enviale ese HWID al vendor para que genere tu token.

{
  "name": "hana_show_license_info",
  "arguments": {}
}

Una vez instalado el token, la misma tool debe reportar:

status: VALID
plan: enterprise
features: ["hana", "knowledge-base"]

🔌 Uso con Claude / VS Code / MCP Inspector

Ejemplo de mcp.json:

{
  "mcpServers": {
    "hana": {
      "type": "stdio",
      "command": "C:\\hana-mcp-client\\hana-mcp-server.exe"
    }
  }
}

🔄 Actualizaciones

El servidor nunca se actualiza solo. Cuando haya una nueva versión, el vendor la publicará en Releases. Podés consultarla con la tool hana_check_for_updates y aplicarla con hana_apply_update:

{
  "name": "hana_apply_update",
  "arguments": {
    "confirm": true
  }
}

El proceso preserva tus casos propios (docs/kb/user/), los casos sincronizados desde la nube (docs/kb/remote/) y tu configuración (.env, .hana-license, mcp.json). Los casos incluidos con el producto (docs/kb/bundled/) sí se actualizan.

📁 Contenido del paquete

  • hana-mcp-server.exe — MCP empaquetado con Node.js.

  • start.bat — lanzador para Windows.

  • docs/kb/bundled/ — base de conocimiento incluida con el producto.

  • docs/kb/user/ — casos que crees vos (vacío al inicio).

  • docs/kb/remote/ — casos sincronizados desde el servidor remoto.

  • node_modules/@sap/hana-client/ — driver nativo de SAP HANA.

  • public-key.pem — clave pública para validar licencias.

  • .env.example — plantilla de configuración.

  • mcp.json.example — plantilla de configuración MCP.

  • scripts/update-client.ps1 / update-client.sh — helpers de actualización.

📴 Modo offline (licencia vencida)

Si la licencia expira, el MCP no se cierra: entra en modo offline y mantiene disponible la base de conocimiento local en modo de solo lectura.

  • Funcionan:

    • hana_search_knowledge_base

    • hana_read_kb_case

    • hana_generate_kb_index

    • hana_show_license_info

  • No funcionan hasta renovar la licencia:

    • Todas las tools de consulta y administración de HANA.

    • Guardar nuevos casos (hana_save_knowledge_case).

    • Sincronización remota de KB.

🆘 Soporte

Para renovar la licencia, agregar hardware IDs adicionales o reportar problemas, contactá al vendor con el hardware ID mostrado por hana_show_license_info.

Available Tools

44 tools
hana_apply_updateApply MCP updateA

Download and install the latest HANA MCP client update. Preserves local KB cases and configuration.

Inputs: confirm (required).

hana_check_for_updatesCheck for MCP updatesA
Read-onlyIdempotent

Check if a newer version of the HANA MCP client is available from the vendor license server.

Inputs: no named parameters.

hana_describe_functionDescribe a functionA
Read-onlyIdempotent

Return parameter names, types, data types, and positions for a function from SYS.FUNCTION_PARAMETERS.

Inputs: function_name (required), schema_name, catalog_database.

hana_describe_indexDescribe table indexB
Read-onlyIdempotent

Describe the structure of a specific index

Inputs: index_name (required), table_name (required), schema_name, catalog_database.

hana_describe_procedureDescribe a stored procedureA
Read-onlyIdempotent

Return parameter names, types (IN/OUT/INOUT), data types, and positions from SYS.PROCEDURE_PARAMETERS.

Inputs: procedure_name (required), schema_name, catalog_database.

hana_describe_tableDescribe table structureB
Read-onlyIdempotent

Describe the structure of a specific table

Inputs: table_name (required), schema_name, catalog_database.

hana_describe_viewDescribe a viewA
Read-onlyIdempotent

Return the view definition (SQL) and column metadata from SYS.VIEWS and SYS.VIEW_COLUMNS.

Inputs: view_name (required), schema_name, catalog_database.

hana_execute_queryExecute SQL queryA
Destructive

Execute SQL against HANA. When HANA_QUERY_LIMITS_ENABLED=true, SELECT/WITH queries are wrapped with LIMIT/OFFSET (HANA_MAX_RESULT_ROWS) and row/column/cell caps apply; results are returned as-is otherwise. INSERT/UPDATE/DELETE are blocked by default; set HANA_ALLOW_INSERT, HANA_ALLOW_UPDATE, HANA_ALLOW_DELETE=true individually to permit each. Use limit, offset, maxRows, includeTotal as needed. If truncated, snapshotId may be returned for hana_query_next_page.

Inputs: query (required), limit, offset, maxRows, +3 more. Returns: kind, rows, offset, columns, +9 more

hana_explain_planExplain query execution planA

Run EXPLAIN PLAN for a SELECT/WITH query and return operator tree from EXPLAIN_PLAN_TABLE. Only SELECT/WITH are accepted.

Inputs: query (required).

hana_explain_tableExplain table with business semanticsA
Read-onlyIdempotent

Return column metadata merged with optional business semantics from HANA_SEMANTICS_PATH or HANA_SEMANTICS_URL (JSON keys: SCHEMA.TABLE or DB.SCHEMA.TABLE when catalog_database is set). Optional catalog_database reads SYS.* from another MDC database (e.g. HSP).

Inputs: table_name (required), schema_name, catalog_database. Returns: table, schema, columns, catalog_database, +1 more

hana_generate_kb_indexGenerate knowledge base indexA

Regenerate the docs/kb/index.md file from the saved cases (requires knowledge-base license feature).

Inputs: no named parameters.

hana_get_column_statsGet column statisticsA
Read-onlyIdempotent

Retrieve column statistics (distinct count, null count, min/max) from SYS.COLUMN_STATISTICS (cached) or via live COUNT queries (live=true). With live=true a specific column_name is required.

Inputs: table_name (required), live, column_name, schema_name.

hana_get_ddlGet object DDL definitionA
Read-onlyIdempotent

Retrieve the DDL (CREATE statement) for a TABLE, VIEW, PROCEDURE, FUNCTION, TRIGGER, or SEQUENCE from SYS.OBJECT_DEFINITION. Requires appropriate privileges.

Inputs: object_name (required), object_type, schema_name.

hana_get_dependenciesGet object dependenciesA
Read-onlyIdempotent

Show what an object depends on or what depends on it, from SYS.OBJECT_DEPENDENCIES. Capped at 200 rows.

Inputs: object_name (required), direction, schema_name.

hana_get_expensive_queriesGet top expensive queriesA
Read-only

Return the most expensive statements from M_EXPENSIVE_STATEMENTS ordered by duration. Requires MONITORING privilege.

Inputs: limit.

hana_get_partition_infoGet table partition infoA
Read-onlyIdempotent

Return partition metadata (type, level, record count, loaded state) from SYS.TABLE_PARTITIONS. Returns empty result for unpartitioned tables.

Inputs: table_name (required), schema_name.

hana_get_sample_dataGet sample rows from a tableA
Read-onlyIdempotent

Fetch the first N rows from a table using SELECT TOP. Result is shaped by the same row/column/cell caps as hana_execute_query.

Inputs: table_name (required), limit, schema_name. Returns: kind, rows, offset, columns, +9 more

hana_get_session_infoGet current session infoA
Read-onlyIdempotent

Return CURRENT_USER, CURRENT_SCHEMA, connected database name, SYSTEM_ID, and HANA version from DUMMY and M_DATABASE.

Inputs: no named parameters.

hana_get_table_statsGet table statisticsA
Read-onlyIdempotent

Return row count, table type, column-store flag, primary key flag, and disk size (requires MONITORING privilege for disk size) from SYS.TABLES and SYS.M_TABLE_SIZES.

Inputs: table_name (required), schema_name.

hana_health_checkRun HANA health checkA
Read-onlyIdempotent

Run a read-only diagnostic snapshot against the HANA database: database info, services, memory metrics, top tables by size and blocked-transaction count.

Inputs: schema_name.

hana_list_calculation_viewsList SAP calculation viewsA
Read-onlyIdempotent

List calculation views from the _SYS_BIC schema (SAP BW/S4 analytical views). Supports prefix filter and pagination.

Inputs: limit, offset, prefix.

hana_list_constraintsList table constraintsA
Read-onlyIdempotent

List primary key, unique, check, and foreign key constraints for a table (SYS.CONSTRAINTS + SYS.REFERENTIAL_CONSTRAINTS).

Inputs: table_name (required), schema_name, catalog_database.

hana_list_foreign_keysList foreign keys on a tableA
Read-onlyIdempotent

List referential constraints (foreign keys) showing column, referenced table/column, and delete rule from SYS.REFERENTIAL_CONSTRAINTS.

Inputs: table_name (required), schema_name, catalog_database.

hana_list_functionsList functions in a schemaA
Read-onlyIdempotent

List scalar and table functions from SYS.FUNCTIONS. Supports prefix filter and pagination.

Inputs: limit, offset, prefix, schema_name.

hana_list_indexesList table indexesA
Read-onlyIdempotent

List all indexes for a specific table

Inputs: table_name (required), schema_name, catalog_database.

hana_list_privilegesList effective privilegesA
Read-onlyIdempotent

List effective privileges for a user (or CURRENT_USER if omitted) from SYS.EFFECTIVE_PRIVILEGES. Requires CATALOG READ privilege or querying own privileges.

Inputs: grantee.

hana_list_proceduresList stored procedures in a schemaA
Read-onlyIdempotent

List stored procedures and their parameter counts from SYS.PROCEDURES.

Inputs: limit, offset, prefix, schema_name.

hana_list_schemasList HANA schemasA
Read-onlyIdempotent

List schemas in the HANA database with optional prefix filter and pagination (HANA_LIST_DEFAULT_LIMIT / offset).

Inputs: limit, offset, prefix. Returns: items, returned, truncated, nextOffset, +1 more

hana_list_sequencesList sequences in a schemaA
Read-onlyIdempotent

List sequences from SYS.SEQUENCES, showing start, min, max, increment, cycle, and cache settings.

Inputs: limit, offset, prefix, schema_name.

hana_list_synonymsList synonyms in a schemaA
Read-onlyIdempotent

List synonyms in a schema from SYS.SYNONYMS, showing target object schema, name, and type.

Inputs: limit, offset, prefix, schema_name.

hana_list_tablesList tables in schemaA
Read-onlyIdempotent

List tables in a schema with optional name prefix and pagination (HANA_LIST_DEFAULT_LIMIT / offset).

Inputs: limit, offset, prefix, schema_name, +1 more. Returns: items, returned, truncated, nextOffset, +1 more

hana_list_viewsList views in a schemaA
Read-onlyIdempotent

List views in a schema from SYS.VIEWS. Supports prefix filter and pagination.

Inputs: limit, offset, prefix, schema_name.

hana_memory_monitorMonitor HANA indexserver memoryB
Read-onlyIdempotent

Take a memory snapshot of the HANA indexserver and compare usage against allocation limits. Optionally append the result to a CSV history file.

Inputs: output_file, save_history.

hana_query_next_pageContinue paged queryA
Read-only

Fetch the next page of a truncated SELECT using snapshotId from a previous hana_execute_query result (same SQL and parameters; TTL HANA_QUERY_SNAPSHOT_TTL_MS).

Inputs: offset (required), snapshot_id (required), max_rows. Returns: kind, rows, offset, columns, +9 more

hana_read_kb_caseRead knowledge caseA
Read-onlyIdempotent

Read the full Markdown content of a local or remote knowledge base case by filename. Available even in offline mode when the license is expired.

Inputs: filename (required).

hana_realtime_performanceRealtime HANA performance snapshotA
Read-onlyIdempotent

Live performance indicators: open transactions, top SQL plan cache queries by total time and frequency, long connections, column-store delta sizes and blocked transactions.

Inputs: schema_name.

hana_save_knowledge_caseSave knowledge caseA

Save a resolved incident or finding to the local Markdown knowledge base (requires active knowledge-base license feature).

Inputs: title (required), tags, cause, status, +9 more.

hana_search_columnsSearch columns by name patternA
Read-onlyIdempotent

Find all columns matching a LIKE pattern across all tables (or within a schema). Uses SYS.TABLE_COLUMNS. Results capped at 1000.

Inputs: column_pattern (required), limit, schema_name.

hana_search_knowledge_baseSearch knowledge baseA
Read-onlyIdempotent

Search the local Markdown knowledge base for previous cases (requires knowledge-base license feature).

Inputs: query (required), limit.

hana_search_tablesSearch tables by name patternA
Read-onlyIdempotent

Find all tables matching a LIKE pattern across all schemas (or within a specific schema). Uses SYS.TABLES. Results capped at 2000.

Inputs: table_pattern (required), limit, schema_name.

hana_show_configShow HANA configurationB
Read-onlyIdempotent

Show the HANA database configuration

Inputs: no named parameters.

hana_show_env_varsShow HANA env varsA
Read-onlyIdempotent

Show all HANA-related environment variables (for debugging)

Inputs: no named parameters.

hana_show_license_infoShow license infoA
Read-onlyIdempotent

Show current license status, hardware ID, plan and expiration.

Inputs: no named parameters.

hana_test_connectionTest HANA connectionB
Read-onlyIdempotent

Test connection to HANA database

Inputs: no named parameters.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 44 tools

    Disambiguation4/5

    Most tools are clearly distinct by resource (tables, views, indexes, procedures, etc.) and action (list, describe, search). Minor overlap exists between list_constraints and list_foreign_keys, and describe_table vs explain_table, but descriptions clarify the differences.

    Naming Consistency5/5

    All tool names follow a consistent hana_verb_noun pattern using snake_case. Verbs like list, describe, get, search, and execute are used systematically across resource types.

    Tool Count2/5

    At 44 tools, the server is quite large, exceeding the 'heavy' threshold of 25. While each tool has a narrow purpose, the sheer number may overwhelm an agent, though the broad SAP HANA scope partially justifies the count.

    Completeness5/5

    The tool set covers a comprehensive range of HANA metadata exploration, querying, performance monitoring, and even knowledge base management. Read-only operations for tables, views, indexes, constraints, procedures, functions, sequences, privileges, and dependencies are all present, leaving few obvious gaps.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      B
      quality
      Not graded
      maintenance
      An MCP server that enables AI assistants to interact with SAP systems via the ABAP Development Tools (ADT) REST API. It allows users to read ABAP source code, inspect DDIC objects, and execute SQL queries directly.
      66
      -
    • A
      license
      A
      quality
      C
      maintenance
      Production-ready MCP server that enables AI assistants to seamlessly interact with SAP Datasphere environments for real tenant data discovery, metadata exploration, analytics operations, ETL data extraction, database user management, data lineage analysis, and column-level data profiling.
      39
      64 npm
      136 PyPI
      50
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server for SAP HANA that enables listing tables, columns, running SQL queries, and looking up SAP table descriptions, all through natural language via AI assistants.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that gives AI assistants direct access to SAP HANA performance data — query plans, execution stats, memory usage.
      MIT