Hey Guys i have a db and corresponding

Hey Guys, i have a db and corresponding preview, but now i can't apply mirgations since it returns an error
✘ [ERROR] Can't find a DB with name/binding 'preview-mydb' in local config. Check info in wrangler.toml...
✘ [ERROR] Can't find a DB with name/binding 'preview-mydb' in local config. Check info in wrangler.toml...
but i have a definition like so
[[d1_databases]]
binding = "DB"
database_name = "mydb"
database_id = "main-id"
preview_database_id = "preview-id"
[[d1_databases]]
binding = "DB"
database_name = "mydb"
database_id = "main-id"
preview_database_id = "preview-id"
1 Reply
DarkMatter
DarkMatterOP15mo ago
Ok i make it work but basically duplicated the definition for the database (which looks a bit weird) Something funny after running the migration is that UI shows 2 tables, but CLI says only 1 exists (real number 1) ok it might be the migrations table ...
Want results from more Discord servers?
Add your server