Plan is successful and only when I hit apply I get this:
module.rds.mssql_database.rds_db[1]: Creating...
module.rds.mssql_database.rds_db[2]: Creating...
module.rds.mssql_database.rds_db[0]: Creating...
module.rds.mssql_database.rds_db[1]: Creation complete after 7s [id=6]
╷
│ Error: Could not execute SQL
│
│ with module.rds.mssql_database.rds_db[0],
│ on ....\modules\rds\sql-setup.tf line 11, in resource "mssql_database" "rds_db":
│ 11: resource "mssql_database" "rds_db" {
│
│ mssql: The transaction ended in the trigger. The batch has been aborted.
╵
╷
│ Error: Could not execute SQL
│
│ with module.rds.mssql_database.rds_db[2],
│ on ....\modules\rds\sql-setup.tf line 11, in resource "mssql_database" "rds_db":
│ 11: resource "mssql_database" "rds_db" {
│
│ mssql: The transaction ended in the trigger. The batch has been aborted.
So in general it creates only one DB from list and others fail. I can rerun apply again, then again it will only create another missing DB and other remaining will fail.
The same when for_each is used.
Any idea what is going on here?
Hi, have a problem trying to create multiple db's using count. My code is:
Plan is successful and only when I hit apply I get this:
So in general it creates only one DB from list and others fail. I can rerun apply again, then again it will only create another missing DB and other remaining will fail. The same when for_each is used. Any idea what is going on here?