Monday, March 26, 2012

grant exec to windows account

When i do
grant exec on sproc1 to 'domain\user'
it returns
Server: Msg 170, Level 15, State 1, Line 1
Line 1: Incorrect syntax near 'domain\user'Hi John
Use [ ] instead of quotes:
grant exec on sproc1 to [domain\user]
--
HTH
Kalen Delaney, SQL Server MVP
www.InsideSQLServer.com
http://blog.kalendelaney.com
"John Doe" <Johndoe@.jd.com> wrote in message
news:Oj4ImmmbIHA.1212@.TK2MSFTNGP05.phx.gbl...
> When i do
> grant exec on sproc1 to 'domain\user'
> it returns
> Server: Msg 170, Level 15, State 1, Line 1
> Line 1: Incorrect syntax near 'domain\user'
>

No comments:

Post a Comment