I have a SQL restore script (file on file system) that contains a list of databases to be restored like so:
RESTORE DATABASE DB1... RESTORE DATABASE DB2... RESTORE DATABASE DB3...
I then have an object that contains a list of databases that are already online.
$onlineDatabases.Database outputs DB1 DB2
How can I return a new restore script that contains only the DB3 database?