I recently automatize deployment of SSIS projects and SQL Server database with powershell scripts. I use SQLPackage.exe (dacpac framework) to deploy .dacpac in order to automatize update database structure. My issue: Dacpac try to rebuild huge tables and fail with following error message as "transaction log full".
I found a solution by copying all data in temporal database, truncating actual database, update with dacpac and copying data back. Really important points to notice:
- I must save data somewhere.
- During copy of data I explicitly copy data in small batches of 50000 lines and clean database log file to prevent error.
My question: is there an option in SQLPackages /deploy which allow to handle this process more easily? Or another way I did not think of?