Results 1 to 5 of 5
  1. #1
    Join Date
    Dec 2004
    Posts
    7

    Unanswered: Sql Server 2005 Extended Procedures

    Hi,

    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?

    Thanks,
    V.

  2. #2
    Join Date
    May 2004
    Location
    Seattle
    Posts
    1,313
    they are supported in 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.

  3. #3
    Join Date
    Dec 2005
    Location
    Tilburg, Netherlands
    Posts
    73
    Quote Originally Posted by jezemine
    I can't remember what windows account is used for this - probably it's the one that sqlservr.exe is running as.
    Yes it is.

    Gr,
    Yveau

    > SELECT * FROM users WHERE clue > 0;
    Empty set (0.00 sec)


  4. #4
    Join Date
    Dec 2004
    Posts
    7
    Thanks for the quick replies. I assume that this would also require a restart of the SQL service once the permission updates to the registry keys were made?

  5. #5
    Join Date
    May 2004
    Location
    Seattle
    Posts
    1,313
    It shouldn't require a restart. If you have modified the ACLs on the reg key to give the sqlservr.exe account access, sql server should be able to read them now.

    If you changed the acct that the service is running as, that DOES require a restart to take effect.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •