Live data from Hacker News

Show HN: ChartDB Agent – Cursor for DB schema design

app.chartdb.io

11–20 of 37 posts

Re: Show HN: ChartDB Agent – Cursor for DB schema design

#11
post #8

My conversation "Design a schema like Calendly" --> Did it "OK let's scale this to 100m users" --> Tells me how it would. No schema change. "Did you update the schema?" --> Updates the schema, tells me what it did. We've been running into this EXACT failure mode with current models, and it's so irritating. Our agent plans migrations, so it's code-adjacent, but the output is a structured plan (basically: tasks, which…

isnt this what the agents are for, you assign them jobs to make changes then evaluate those changes. there is a necessary orchestration piece and maybe even a triage role to sort through things to do and errors to fix

Re: Show HN: ChartDB Agent – Cursor for DB schema design

#12
In my experience most AI coding tools can work with databases, especially if you give it an MCP tool to connect to your (development) database. It will generate mermaid er-diagrams by reading from your database catalog, it will generate SQL to create tables, views, etc. It will generate queries, validate them and return data. It will optimize your query performance by running the query, running explain plan, looking into pg_stat_statements (or whatevery your database uses), and propose SQL optimization, indexes to be created. It will also create demo data with realistic use cases like black friday or back to school discounts for prices, etc.

A SQL MCP + mermaid is all you need.

Btw, it can also do an awesome job turning query plans into readable mermaid flow diagrams, adding details to the chart, using color to highlight bottlenecks.

Re: Show HN: ChartDB Agent – Cursor for DB schema design

#13

This is super cool! Have you thought about making a tool to help preview/dry run migrations? I feel that's something I would want a ton of confidence in if an LLM is making migration scripts. Especially if it's doing scary stuff like breaking up a table.

How do you expect an LLM to help here? Can't you just use OverlayFS on the database volume, or a backup thereof, and run the migration against that?

Re: Show HN: ChartDB Agent – Cursor for DB schema design

#17
post #12

In my experience most AI coding tools can work with databases, especially if you give it an MCP tool to connect to your (development) database. It will generate mermaid er-diagrams by reading from your database catalog, it will generate SQL to create tables, views, etc. It will generate queries, validate them and return data. It will optimize your query performance by running the query, running explain plan, looking…

Agreed

Re: Show HN: ChartDB Agent – Cursor for DB schema design

#19
It'd be nice if it also included the queries for each use case, and had a better understanding of sharding. As is, I gave it a bunch of requirements, it created some tables. Was it sufficient? No idea, it didn't say what the query was for each requirement. Would it scale? Again, no idea without the queries. (But actually, no, it wouldn't have scaled; some requirements were impossible without cross-shard scans).
Post reply on HN