{
  "id": 7289767,
  "title": "Your AI SDK chat table breaks every six months",
  "url": "https://urgent.news/2026/09/14/your-ai-sdk-chat-table-breaks-every-six-months",
  "topic": "ai",
  "section": "AI",
  "published": "2026-09-14T09:55:34.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/nixrajput/your-ai-sdk-chat-table-breaks-every-six-months-6eb"
  },
  "original_language": "en",
  "account": "The AI SDK chat table breaks every six months. In the open lib/db/schema.ts of Vercel's ai-chatbot template, the Message_v2 table was introduced when the message shape changed during an update. However, migrating the existing table in place proved challenging, leading to the addition of Message_v2 and Vote_v2 tables, with the originals eventually being deleted. The old tables now carry their version numbers permanently in the schema for every new project that forks from the template.",
  "summary": "Open lib/db/schema.ts in Vercel's ai-chatbot template and look at line 42: export const message = pgTable ( \" Message_v2 \" , { The _v2 is a scar. When ai 5 changed the message shape, migrating the existing table in place was harder than adding a new one beside it, so the template added Message_v2 and Vote_v2 , backfilled, and eventually deleted the originals. The old tables are gone now. The…",
  "key_points": [
    "AI SDK chat table breaks every six months",
    "Messagev2 table added for shape change",
    "Old tables deleted, version numbers retained"
  ],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}