How can we help you today? How can we help you today?

Redgate Source Control: Securables from synced database roles getting overwritten

I have several database roles synced between a test and production server with redgate source control. These are properly connected to their appropriate role members.

Once I make a new deployment to the production server, the permissions that are granted to individual database roles are reset. The connection to the role members, however, stays.So all of the settings here (picture) get deleted.

enter image description here

How can I prevent this from happening? Do Securables have to be synced separately? If so, where?

iremin
0

Comments

2 comments

  • DanC
    Hi @iremin

    Securables are database level objects that can't be committed and checked into SQL Source Control.

    In this case, are you referring to permissions? if you're using SQL Change Automation PowerShell for deployment of these source controlled databases, by defaultĀ  the following option is enabledĀ "Ignore User Permissions and Role Memberships enabled", if you're assigning permissions directly to users, this will explain the behavior.

    Hope this helps!
    DanC
    0
  • iremin
    Thank you. I have included roles to an exclude filter and no longer have the issue.
    iremin
    0

Add comment

Please sign in to leave a comment.