Skip to content

Changing vector size in model does not seem to update the database when doing a migration #3745

Closed

Description

@vlidholt

Describe the bug

After doing a migration and applying it, I still get this error message when starting the server.

WARNING: The database does not match the target database:
 - Table "rag_document" is not like the target database:
 - Column "embedding" mismatch: 
   - expected vector dimension "768", found "1536".

To reproduce

  1. Create a table with a vector field of dimension 1536. Create and apply migration.
  2. Change the dimension to 768, create and apply a (forced) migration.
  3. Start the server and the error message above is displayed.

Expected behavior

The vector dimension is expected to be correct (768 in the example above)

Library version

2.9

Platform information

MacOS

Additional context

No response

How experienced are you with this library?

Expert - Experienced and comfortable with using this library in complex projects

Are you interested in working on a PR for this?

  • I want to work on this

Activity

  1. added
    bug
    on Jul 1, 2025
  2. added
    area: database
    on Aug 8, 2025
  3. moved this from Inbox 📫 to Bugs 🐞 in Serverpod Frameworkson Aug 8, 2025
  4. moved this from Bugs 🐞 to Planned 🔭 in Serverpod Frameworkson Aug 14, 2025
  5. moved this from Planned 🔭 to Backlog 🗂️ in Serverpod Frameworkson Oct 24, 2025
  6. moved this from Backlog 🗂️ to Done 🚀 in Serverpod Frameworkson Nov 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area: databasebug

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions