question

Job_Antony avatar image
Job_Antony asked

I was trying to create a Job for invalid objects that could check the invalid objects of all user DB and send a report to our mail. please help me on this scripting.

We have query for finiding invalid object for one database, But i need to get invalid object for all User db and send it through mail.
invalid-character
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Usman Butt avatar image
Usman Butt answered
Please have a look at [Making a more reliable and flexible sp_MSforeachdb][1] to get the required information from all the databases. If it does not fulfill your requirement, then you can easily modify it according to your needs or at least get the basic idea. [1]: https://www.mssqltips.com/sqlservertip/2201/making-a-more-reliable-and-flexible-spmsforeachdb/
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.