No MCP server required! Databasemix allows you to consolidate MySQL table information into a single file for easy AI integration.

This is Yuta Kikai (@fat47) from the Service Reliability Group (SRG) of the Media Division.
#SRGThe Service Reliability Group primarily provides comprehensive support for the infrastructure surrounding our media services, focusing on improving existing services, launching new ones, and contributing to open-source software (OSS).
This article discusses how using a tool called databasemix to consolidate MySQL table information into a single file is proving useful for AI applications.
I hope this is of some help.
 

What is databasemix?


When you need to have an AI coding support tool access MySQL table information, how do you usually do it?
Copying and pasting database information is cumbersome because you have to enter it every time, and you also need to be careful to ensure that the information you enter is up-to-date.
Allowing direct access to the database via an MCP server requires careful consideration of security, and it also involves the extra step of setting up an MCP server for each user.
 
By setting up the system using databasemix, which we will introduce here, you can create an environment where AI can always access the latest MySQL table information without needing an MCP server.
 
databasemixMySQL Unconference #010 in@tom__boThis open-source software, which was announced by [Name], was developed based on the concept of repomix and has the functionality to output MySQL information to a single file.
 
You can select and output user and role information, table structure, MySQL server variables, and other data to a single file.
For more details, please refer to @tom__bo's blog.

How to easily utilize AI for the output of database mix


Configuration diagram

 
We run databasemix on an EC2 server and place the output files on a GitHub repository. The output only includes table configuration information and does not include database user information or role information.
Due to the nature of my environment, I have multiple database clusters, which generates a large number of markdown files.
Since having separate files for each cluster was inconvenient when using it with AI, we've added a process to concatenate and output the table configuration information of all clusters into a single file (00_all-tables.md).

Use Cloud Code

00_all-tables.md
Example: Rules in CLAUDE.md
Furthermore, since table configuration information is updated daily, I've also implemented a process that uses Claude Code's Hooks feature to constantly pull the latest information.
Example: Add a process to ~/.claude/settings.json to automatically read from a specific path and pull when using Grep.
 
By doing this, coding assistance AIs like Claude Code will always refer to the latest table information when providing answers.
 

Summary and future expectations


By simply cloning a GitHub repository, the AI ​​can now always access the latest MySQL table information.
I think the biggest advantage is that it doesn't require setting up an MCP server, so I'd like to encourage many users (product development teams) to use it going forward.
 
Not currently supportedHowever, if IAM database authentication is supported when using Aurora MySQL,RDS Data APIWith this feature available, it's conceivable that execution could be done directly from GitHub Actions without needing a stepping stone.
I also hope for support for databases other than MySQL!
 
 

If you are interested in SRG, please contact us here.