You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When mssql_schema_permission depends on the user (which should be created before), I get an error that schema and database must belong to the same database.
If I create a plan with mssql_sql_user only, apply it, and then create the next one (which wants to create mssql_sql_user only), there is no error.
Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
+ create
Terraform planned the following actions, but then encountered a problem:
# mssql_sql_user.user will be created
+ resource "mssql_sql_user""user" {
+ database_id = "56"
+ id = (known after apply)
+ login_id = "0x010600000000006400000000000000008875E4B7A6B3064D8F72C34AC9869B0A"
+ name = "bg_test"
}
Plan: 1 to add, 0 to change, 0 to destroy.
╷
│ Error: Schema and Principal must belong to the same DB
│
│ with mssql_schema_permission.schema_permission,
│ on main.tf line 75, in resource "mssql_schema_permission""schema_permission":
│ 75: resource "mssql_schema_permission""schema_permission" {
│
│ schema_id points to DB with ID 56 while principal_id points to DB with ID 0
╵
The text was updated successfully, but these errors were encountered:
When mssql_schema_permission depends on the user (which should be created before), I get an error that schema and database must belong to the same database.
If I create a plan with mssql_sql_user only, apply it, and then create the next one (which wants to create mssql_sql_user only), there is no error.
Configuration:
Output:
The text was updated successfully, but these errors were encountered: