I am trying to run a stored procedure in SQL 2005 which calls a registry value using the RegRead stored procedure which in conjunction executes a line of code. This stored procedure has previously worked in both Sql 7/2000.
However, I am getting the following error when trying to run it in SQL 2005:
Msg 22001, Level 16, State 1, Line 0
xp_regread() returned error 5, 'Access is denied.'
Does anyone know if Extended Stored Procedures are supported in SQL 2005?
From the error message, it looks like you don't have perms to read the reg key you are reading. I can't remember what windows account is used for this - probably it's the one that sqlservr.exe is running as.