dataplat / docs

The documentation for dbatools module. Issues with command doc and bugs should be reported to dataplat/dbatools.
https://docs.dbatools.io
15 stars 12 forks source link

Copy-DbaDbTableData hangs SELECT query when script is 'cancelled' in Powershell ISE #55

Closed datadill closed 3 years ago

datadill commented 3 years ago

I am not sure if this is intentional behavior, a problem that can't be fixed, or a bug.. but when using the Copy-DbaDbTableData I ran into an issue where I was moving data from a production secondary down to our dev environment for a developer and hit the 'stop' button in my Powershell ISE before the first batch could complete. I found out 10 days later that the "SELECT *" on the table was still running and I am not sure if it was because of the size of the table or because their was no longer any communication to my ISE occurring. This ultimately caused version store to fill-up on the secondary and eventually tempdb.

Expected behavior would be to kill the query once the ISE shows everything as being stopped.

This can easily be repeated in a test environment.

datadill commented 3 years ago

Moved to: https://github.com/sqlcollaborative/dbatools/issues/7397