Have you google it ? i am not sure you can get any script which will work for both table and SP. but individual script will be there. So happy hunting 🙂
-------Bhuvnesh----------
I work only to learn Sql Server...though my company pays me for getting their stuff done;-)