Excluding backups by status/type instead of name
Is there a command I can put into my batch files that will exclude databases in standby? Offline? Snapshots?
Specific reason I'm asking the question, I received the following error in the details of a database backup. There were 3 snapshots listed and one database that is in standby / read-only. This cropped up very recently. I don't know if the databses are there when the batch starts and gone when it finally starts to run them or what.
USER - Backup operation inhibited because database SODA_PROD_Demographics_TA_ss does not exist.