用扩展存储过程xp_cmdshell,不过要有sa的权限才能执行
最经典的就是
你使用超级用户登陆到对方机器名xx的sql server中。exec xp_cmdshell 'net send xx 我原来是个猪头阿!'
执行后
对方的显示器上就会出现 xx 对 xx说 我原来是个猪头阿!
哈哈