Copy-DbaDatabase command does not throw warnings or error messages when I accidentally passed in a non-existing source database #9338
Unanswered
somusomesh756
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Copy-DbaDatabase command does not throw warnings or error messages when I accidentally passed in a non-existing source database. How do I handle these cases and print a message so the user consuming my automation knows what's happening? Am I missing something? I can write my own scripts to check if database exists, but if possible, I would like to use the inbuilt features of copy-DbaDatabase command.
Here is the output from using -Verbose switch:
VERBOSE: [14:51:51][Copy-DbaDatabase] Writing warning about filestream being enabled.
VERBOSE: [14:51:51][Copy-DbaDatabase] Building database list.
VERBOSE: [14:51:51][Copy-DbaDatabase] Performing count.
VERBOSE: [14:51:51][Copy-DbaDatabase] Building file structure inventory for 0 databases.
VERBOSE: [14:51:51] [Copy-DbaDatabase ]
Database migration finished
VERBOSE: [14:51:51][Copy-DbaDatabase] Migration started: 04/29/2024 14:51:51
VERBOSE: [14:51:51][Copy-DbaDatabase] Migration completed: 04/29/2024 14:51:51
VERBOSE: [14:51:51][Copy-DbaDatabase] Total Elapsed time: 00:00:00
Beta Was this translation helpful? Give feedback.
All reactions