It finds the Indexes on database which needs to be Defragmented and Rebuilds those indexes.
Only you need to replace 'database_name' with your database.
Include this Stored Procedure in to your Scheduled JOB, schedule it whenever you want.
Enjoy The Code...!