- Home
- MCP servers
- CData's Model Context Protocol (MCP) Server for CSV Files
CData's Model Context Protocol (MCP) Server for CSV Files
- java
0
GitHub Stars
java
Language
7 months ago
First Indexed
3 months ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
You can query live data from CSV files using a read-only MCP server that exposes CSV data via the CData JDBC Driver. This server lets you ask natural language questions and receive live results without writing SQL, ideal for AI assistants and data exploration on CSV datasets.
How to use
You interact with the MCP server through an MCP client. The server provides a set of tools to discover what data is available and to retrieve data from your CSV sources. Use natural language queries or the built-in tools to explore tables, view columns, or execute read-only queries. You can ask questions like, “What is the total revenue by region this quarter?” or “Show me open tickets in the SUPPORT project.” The server exposes a small, explicit set of tools that you can call to inspect tables, inspect columns, or run a SELECT query to fetch data.
How to install
Prerequisites: ensure you have a Java runtime and Maven installed on your system.
# 1. Clone the MCP server repository
# Replace with your preferred path
git clone https://github.com/cdatasoftware/csv-files-mcp-server-by-cdata.git
cd csv-files-mcp-server-by-cdata
# 2. Build the MCP server
mvn clean install
# 3. The build creates the JAR: CDataMCP-jar-with-dependencies.jar
Prepare the CData JDBC Driver for CSV Files and license it. Follow these steps to install and license the driver.
# Download the CData JDBC Driver for CSV Files (driver package URL is provided by CData)
# After download, license the driver
# Locate the lib folder in the installation directory
# Windows example: C:\Program Files\CData\CData JDBC Driver for CSV Files\
# Mac/Linux example: /Applications/CData JDBC Driver for CSV Files/
java -jar cdata.jdbc.csv.jar --license
Configure a connection to your data source using the JDBC Driver. Open the connection utility and test the connection, then copy the connection string for use in the server configuration.
java -jar cdata.jdbc.csv.jar
Create a property file for the JDBC connection. Save it as csv-files.prp with your details.
env
Prefix=csv
ServerName=CDataCSV
ServerVersion=1.0
DriverPath=PATH\\TO\\cdata.jdbc.csv.jar
DriverClass=cdata.jdbc.csv.CSVDriver
JdbcUrl=jdbc:csv:InitiateOAuth=GETANDREFRESH;
Tables=
Additional setup for running with Claude Desktop
To enable Claude Desktop to access the MCP server, create a Claude configuration that points to the MCP server. If you already have a Claude config file, add the MCP server entry under mcpServers. The following example shows how to define an MCP server that runs locally.
{
"mcpServers": {
"csv_files": {
"command": "PATH\\TO\\java.exe",
"args": [
"-jar",
"PATH\\TO\\CDataMCP-jar-with-dependencies.jar",
"PATH\\TO\\csv-files.prp"
]
}
}
}
Running the server
Start the MCP server using the Java runtime and the prepared .prp configuration. The server runs locally and uses stdio for communication with the client.
java -jar /PATH/TO/CDataMCP-jar-with-dependencies.jar /PATH/TO/Salesforce.prp
Usage notes
You will interact with the server through the MCP client’s tools. The available tools let you retrieve the list of tables, list columns for a table, and run a read-only query. Use these tools to build queries that answer your questions about the data without needing to write SQL.
Troubleshooting
If you cannot see the MCP server in your client, ensure you have fully quit and restarted the client so the new server appears. If the client cannot retrieve data, double-check the connection string in your .prp file and ensure the driver is licensed correctly. If you still have issues, contact CData Support or join the CData Community for help.
Notes
This MCP server is read-only and designed to expose live data from CSV sources. You can mix local configuration with your client tooling to query data efficiently.
Available tools
csv_files_get_tables
Retrieves a list of tables available in the data source. The output is CSV with a header row.
csv_files_get_columns
Retrieves a list of columns for a specific table. The output is CSV with a header row.
csv_files_run_query
Executes a SQL SELECT query against the data source and returns the results.