私は web.config 変換ファイルの概念に取り組んでいます。私は3つのWeb構成を持っています。1 つは、ステージング、プロダクション、デプロイです。これら 3 つの異なる接続情報があります。
Web.Config:
<connectionStrings>
<add name="MyGallery"
connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=DevelopmentStorageDb;Data Source=BALA\SQLEXPRESS" />
</connectionStrings>
Web.Config.Production:
<add
name="MyGallery"
connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=SharePoint_Config;Data Source=BALA\SQLEXPRESS"
xdt:Transform="Replace" xdt:Locator="Match(name)"
/>
これで、正常に動作するコードをビルドします。パッケージを作成しました。プロダクション モードでコードを実行すると、新しい接続文字列が使用されません。
どうすればこれを解決できますか。これをどこかに移動するのに余分な労力が必要ですか