SQL Server only. Checks, before an app's migrations run against an EXISTING schema, that the
executing login may run them: migrations write the schema's Skyway history table and GRANT
on the objects they create, and both need CONTROL on the schema. Its owner and db_owner members
have that; a login that neither owns the schema nor was granted CONTROL does not. That is the
state the README retrofit (MJ#4756) leaves a db_ddladmin installer in once dbo owns the
schema. Verified on SQL Server 2022: its history INSERT is denied, its GRANT fails with
Msg 15151, and HAS_PERMS_BY_NAME(…, 'SCHEMA', 'CONTROL') predicted both outcomes for owner,
db_owner, db_ddladmin (with and without db_datawriter) and an explicit GRANT CONTROL ON SCHEMA.
Install's create path does not need this: CreateAppSchema leaves the installer as owner
unless it has CONTROL on the database.
Success: false with the owner, the login and the remedies when the login lacks
CONTROL; Success: true when it has it, when the schema does not exist yet, or on PostgreSQL
SQL Server only. Checks, before an app's migrations run against an EXISTING schema, that the executing login may run them: migrations write the schema's Skyway history table and
GRANTon the objects they create, and both need CONTROL on the schema. Its owner and db_owner members have that; a login that neither owns the schema nor was granted CONTROL does not. That is the state the README retrofit (MJ#4756) leaves a db_ddladmin installer in oncedboowns the schema. Verified on SQL Server 2022: its history INSERT is denied, itsGRANTfails with Msg 15151, andHAS_PERMS_BY_NAME(…, 'SCHEMA', 'CONTROL')predicted both outcomes for owner, db_owner, db_ddladmin (with and without db_datawriter) and an explicitGRANT CONTROL ON SCHEMA.Install's create path does not need this: CreateAppSchema leaves the installer as owner unless it has CONTROL on the database.