Trying to run a command from CMD that will pull the sqlcmd and then execute my command all in one line.
When I run it, I get an error for EXEC
SQLCMD -S Server\Instance; EXEC master..sp_addsrvrolemember @loginame = N'NT AUTHORITY\SYSTEM', @rolename = N'sysadmin'
This is the error I get:
Sqlcmd: 'EXEC master..sp_addsrvrolemember @loginame = N'NT AUTHORITY\SYSTEM', @rolename = N'sysadmin'': Unexpected argument. Enter '-?' for help.