I'm trying to work out how to set the default profile for the distribution agent programatically using t-sql. I see there is the sp_help_agent_profile and sp_help_agent_default sprocs which allow you to find out what the default is, but they don't allow you to set it.
Is there a sproc, or should I be directly updating the MSagent_profiles table?