home / mcp / sap erp mcp server

SAP ERP MCP Server

This read-only MCP Server allows you to connect to SAP ERP data from Claude Desktop through CData JDBC Drivers. For full CRUD support, check out our MCP Server for SAP ERP (https://www.cdata.com/drivers/sap/download/mcp).

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "cdatasoftware-sap-erp-mcp-server-by-cdata": {
      "command": "java",
      "args": [
        "-jar",
        "/PATH/TO/CDataMCP-jar-with-dependencies.jar",
        "/PATH/TO/sap-erp.prp"
      ]
    }
  }
}

You can query live SAP ERP data through a read-only MCP server that wraps the CData JDBC Driver. This lets large language models and other MCP clients access SAP ERP information directly via natural language questions, without writing SQL.

How to use

You use this MCP server by starting the local process on the same machine as your MCP client. The MCP server exposes SAP ERP data through a simple interface that your client can invoke to read data. After the server is running, ask your MCP client questions like “What is the status of key accounts now?” or “Show me recent SAP ERP orders by region.” The client will use the built-in tools to discover available tables, view columns, and run read-only queries against your SAP ERP data. The server operates in a read-only mode, so you can retrieve information but cannot modify it through this MCP interface.

How to install

Prerequisites: You need a Java Runtime Environment (JRE) or Java Development Kit (JDK) installed on your machine. You also need Maven to build the MCP server and access to the CData JDBC Driver for SAP ERP.

Step 1: Clone the MCP server project and navigate into the folder.

git clone https://github.com/cdatasoftware/sap-erp-mcp-server-by-cdata.git
 cd sap-erp-mcp-server-by-cdata

Step 2: Build the MCP server to create the runnable JAR.

mvn clean install

Step 3: Download and install the CData JDBC Driver for SAP ERP from the official source. Follow the installer prompts for your operating system.

Step 4: License the CData JDBC Driver. Open a terminal in the driver installation’s lib directory and run the license command, then provide your name, email, and license key (or TRIAL).

java -jar cdata.jdbc.saperp.jar --license

Step 5: Create the JDBC connection string using the driver’s utility, then test the connection. Copy the resulting connection string for later use.

java -jar cdata.jdbc.saperp.jar

Step 6: Create a .prp configuration file for the JDBC connection. Save it as sap-erp.prp in a secure location. Include the required fields shown in the example.

env

Prefix=saperp
ServerName=CDataSAPERP
ServerVersion=1.0
DriverPath=PATH\\TO\\cdata.jdbc.saperp.jar
DriverClass=cdata.jdbc.saperp.SAPERPDriver
JdbcUrl=jdbc:saperp:InitiateOAuth=GETANDREFRESH;
Tables=

Step 7: Ensure the SAP ERP data source is accessible through the JDBC driver and that the .prp file references the correct path to the driver JAR and the JDBC URL.

Step 8: Start the MCP server using the standard Java command, pointing to the generated sap-erp.prp file.

java -jar /PATH/TO/CDataMCP-jar-with-dependencies.jar /PATH/TO/sap-erp.prp

Configuration and running the server

The server runs locally and communicates with your MCP client via stdio. This means the client and server reside on the same machine. You will typically start the MCP server with a single command that loads your prp configuration.

Next steps after starting the server: use your MCP client to discover available tables, inspect columns, and issue read-only queries against SAP ERP data. The client tools will provide access to the following capabilities: listing tables, listing columns for a table, and running SELECT queries.

Troubleshooting and notes

If you cannot see or connect to the MCP server, ensure that you fully terminate any previous client sessions and restart the client. Double-check that the sap-erp.prp file contains the correct DriverPath and JdbcUrl values, and that the CData JDBC Driver is licensed correctly.

If the client cannot retrieve data, verify the connection string works by testing it with the JDBC driver’s connection utility. Confirm OAuth or authentication steps are completed in the browser if the data source requires it.

If you run into issues with the MCP server, reach out to CData Support or the CData Community for guidance.

Available tools

sap_erp_get_tables

Retrieves a list of tables available in the SAP ERP data source. The output is in CSV format with column headers on the first line.

sap_erp_get_columns

Retrieves a list of columns for a specific table. The output is in CSV format with column headers on the first line.

sap_erp_run_query

Executes a SQL SELECT query against the SAP ERP data source and returns the results.