Re: Change UDF Owner



It's because sa doesn't own the database objects, but dbo can.

EXECUTE sp_changeobjectowner 'fn_replgetagentcommandlinefromjobid', 'dbo'

should work for you.

--
Arnie Rowland
"To be successful, your heart must accompany your knowledge."



"A McGuire" <allen.mcguire@xxxxxxxxxxxxxxxxx> wrote in message
news:Ok8BDKqqGHA.4932@xxxxxxxxxxxxxxxxxxxxxxx
Can I change the owner of a UDF?

Example:

USE master
GO
EXEC sp_changeobjectowner 'fn_replgetagentcommandlinefromjobid', 'sa'

... isn't working. I want dbo to own all the objects in my database -
just a security best practice sort of thing. I can't seem to find my
answer searching the web.



.