Scripting users
TheBatA
Posts: 18
I am trying to compare 2 databases, db1 is loaded from a snapshot and db2 is database on local server.
I compared two databases, handled differences (I've selected only different tables, other database objects are deselected) and built work object from differences.
When I try to execute schema block, I get this message:
I tried to use IgnoreUsers and IgnorePermissions options, but dbo user is still being scripted.
This user exists in both databases.
How can I exclude creation of user [dbo]?
Thanks!
I compared two databases, handled differences (I've selected only different tables, other database objects are deselected) and built work object from differences.
When I try to execute schema block, I get this message:
User, group, or role 'dbo' already exists in the current database.GetString() method from ExecutionBlock object contains next lines:
CREATE USER [dbo] WITHOUT LOGIN WITH DEFAULT_SCHEMA=[dbo] GO REVOKE CONNECT FROM [dbo] GO
I tried to use IgnoreUsers and IgnorePermissions options, but dbo user is still being scripted.
This user exists in both databases.
How can I exclude creation of user [dbo]?
Thanks!
Comments
Can you post the code that you're using, or send it to michelle.taylor@red-gate.com so I can have a look at it? I might also need to have a look at the databases themselves to work out why it's trying to synchronize dbo.
Redgate Software