Since SQL 2005 you can add .NET dlls into the SQL Assemblies, therefore get called on triggers and event from SQL to do something. Those should be simple utilities as the installation is still quite painful. Now when you are trying to use WCF or WPF dlls...