prisma-engines
f09f2815 - [TML-1610] adjust behavior for default namespace to avoid differences during migrate diff (#5699)

Commit
112 days ago
[TML-1610] adjust behavior for default namespace to avoid differences during migrate diff (#5699) This PR addresses https://github.com/prisma/prisma/issues/28240. When creating the db schema for a schema file we do NOT include the `CREATE SCHEMA public ...`  statement. But when creating it from the migrations (aka shadow db) it is included. Due to this when creating a diff between the two as in migrate diff an actual diff in the db schema is observed. This bug only shows up when using `migrate diff` with the `--exit-only` or `--script` options because of a missing implementation for schemas in the drift summary. This PR fixes the issue by changing the way how we determine the `explicit_namespace` for rendering SQL statements (see https://github.com/prisma/prisma-engines/pull/5614) and ensuring that the default namespace is always part of the namespace list - no matter how the db schema is derived.
Author
Parents
Loading