本文介紹了在部署之前刪除數據庫的數據庫項目?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
限時送ChatGPT賬號..
是否可以讓 VS 在部署之前刪除目標數據庫?
Is it possible to get VS to drop the destination database before a deploy?
我已經嘗試向項目添加部署后腳本,但它總是返回活動連接.
I've tried adding a post deploy script to the project, but it always comes back with active connections.
推薦答案
您需要在數據庫項目的屬性-> 部署-> 部署配置中查找Always recreate database
選項文件 -> 編輯對話框.
You'll need to look up the Always recreate database
option in the properties of the database project -> Deploy -> Deployment configuration file -> Edit Dialog.
另一個選項刪除存在于目標數據庫中但不在模式中的對象"對您也很有用.
Another option "Drop objects that exist in the target database but not in the schema" can also be useful to you.
這篇關于在部署之前刪除數據庫的數據庫項目?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!