Hi,
I know this is a security problem but i am unsure which access i need to give the account, basically im running the stored procedure as below,
exec('CREATE USER ' + '[' + @Login +']' + ' FOR LOGIN [' + @Login + '] WITH DEFAULT_SCHEMA=[dbo]'),
however when a user runs it it will created the user account however it doesn't use the default schema as dbo instead is uses the login name.
It runs fine if i do it so im guessing theres a permission im missing on the dbo schema for the user.
any help would be appreciated. i know this may be better placed in sql server but its an asp.net app that runs the procedure
thank in advance
I know this is a security problem but i am unsure which access i need to give the account, basically im running the stored procedure as below,
exec('CREATE USER ' + '[' + @Login +']' + ' FOR LOGIN [' + @Login + '] WITH DEFAULT_SCHEMA=[dbo]'),
however when a user runs it it will created the user account however it doesn't use the default schema as dbo instead is uses the login name.
It runs fine if i do it so im guessing theres a permission im missing on the dbo schema for the user.
any help would be appreciated. i know this may be better placed in sql server but its an asp.net app that runs the procedure
thank in advance