久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<tfoot id='pNhmX'></tfoot>
    • <bdo id='pNhmX'></bdo><ul id='pNhmX'></ul>

        <small id='pNhmX'></small><noframes id='pNhmX'>

        <i id='pNhmX'><tr id='pNhmX'><dt id='pNhmX'><q id='pNhmX'><span id='pNhmX'><b id='pNhmX'><form id='pNhmX'><ins id='pNhmX'></ins><ul id='pNhmX'></ul><sub id='pNhmX'></sub></form><legend id='pNhmX'></legend><bdo id='pNhmX'><pre id='pNhmX'><center id='pNhmX'></center></pre></bdo></b><th id='pNhmX'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='pNhmX'><tfoot id='pNhmX'></tfoot><dl id='pNhmX'><fieldset id='pNhmX'></fieldset></dl></div>
      1. <legend id='pNhmX'><style id='pNhmX'><dir id='pNhmX'><q id='pNhmX'></q></dir></style></legend>

        在不同的 TFS 分支上工作時丟失 EF 代碼優(yōu)先遷移

        Lose EF Code First Migration when working on different TFS branches?(在不同的 TFS 分支上工作時丟失 EF 代碼優(yōu)先遷移?)
        <tfoot id='66Osi'></tfoot>

            <tbody id='66Osi'></tbody>
            • <i id='66Osi'><tr id='66Osi'><dt id='66Osi'><q id='66Osi'><span id='66Osi'><b id='66Osi'><form id='66Osi'><ins id='66Osi'></ins><ul id='66Osi'></ul><sub id='66Osi'></sub></form><legend id='66Osi'></legend><bdo id='66Osi'><pre id='66Osi'><center id='66Osi'></center></pre></bdo></b><th id='66Osi'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='66Osi'><tfoot id='66Osi'></tfoot><dl id='66Osi'><fieldset id='66Osi'></fieldset></dl></div>
              • <bdo id='66Osi'></bdo><ul id='66Osi'></ul>
                1. <small id='66Osi'></small><noframes id='66Osi'>

                  <legend id='66Osi'><style id='66Osi'><dir id='66Osi'><q id='66Osi'></q></dir></style></legend>
                2. 本文介紹了在不同的 TFS 分支上工作時丟失 EF 代碼優(yōu)先遷移?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                  問題描述

                  限時送ChatGPT賬號..

                  我們正在使用 TFS,并且我們的 Dev 有不同的分支.

                  We are using TFS and have different branches for our Dev.

                  1. 在分支 A 中,我們進(jìn)行了遷移以更改列大小

                  1. in the branch A we made a migration to change a column size

                  在分支 B 中,我們進(jìn)行了遷移以添加新表.這個分支不知道分支A的修改!!

                  in the branch B we made a migration to add a new table. This branch doesn not know about the branch A modification !!

                  兩個修改都合并到主分支.

                  both modification are merged to the main branch.

                  當(dāng)我更新數(shù)據(jù)庫時,它會進(jìn)行 2 次遷移,但最后告訴我有待處理的更改.如果我執(zhí)行添加遷移,它會創(chuàng)建與第一次遷移相同的遷移(在分支 A 中).

                  When I do an update database, it does the 2 migration but at the end tells me there is pending changes. If I do an Add-Migration, it creates the same as the 1st migration (in branch A).

                  無法更新數(shù)據(jù)庫以匹配當(dāng)前模型,因為有待處理更改和自動遷移被禁用.要么寫掛起的模型更改基于代碼的遷移或啟用自動遷移.放DbMigrationsConfiguration.AutomaticMigrationsEnabled 為 true 以啟用自動移民.您可以使用 Add-Migration 命令將掛起的模型更改寫入基于代碼的遷移.

                  Unable to update database to match the current model because there are pending changes and automatic migration is disabled. Either write the pending model changes to a code-based migration or enable automatic migration. Set DbMigrationsConfiguration.AutomaticMigrationsEnabled to true to enable automatic migration. You can use the Add-Migration command to write the pending model changes to a code-based migration.

                  是否因為我上次遷移的屬性 Target de IMigrationMetadata 的內(nèi)容中缺少某些內(nèi)容,因為它不知道第一次遷移?

                  Is it because something is missing in the content of the property Target de IMigrationMetadata of my last migration since it didn't know about the 1st one ?

                  是否可以在不同的 TFS 分支中處理遷移?

                  Is it possible to handle migrations in different TFS branches?

                  推薦答案

                  EF 遷移步驟包含一個元數(shù)據(jù)文件,該文件具有模型簽名,該簽名是遷移步驟的結(jié)果.合并時的問題是在分支 B 中完成的遷移的簽名不包括在分支 A 中的遷移中完成的內(nèi)容.只要遷移在分支中,這是正確的.合并時會出錯.

                  An EF migration step contains a metadata file, that has a signature of the model that is the result of the migration step. The problem when merging is that the signature of the migration done in branch B doesn't include the stuff done in the migration in branch A. As long as the migrations are in the branches, this is correct. When merging it becomes wrong.

                  要解決這個問題,您必須使用

                  To remedy it, you have to regenerate the meta-data of the latter migration with

                  add-migration MyMigrationName
                  

                  在沒有 -force 參數(shù)的現(xiàn)有遷移上運(yùn)行 add-migration 將僅重新生成元數(shù)據(jù).

                  Running add-migration on an existing migration without the -force parameter will regenerate just the metadata.

                  我在 中寫了一篇關(guān)于合并場景的深入演練EF 遷移和合并沖突 在我的博客上發(fā)布.

                  I wrote an in depth walk-through of a merging scenario in the EF Migrations and a Merge Conflict post on my blog.

                  這篇關(guān)于在不同的 TFS 分支上工作時丟失 EF 代碼優(yōu)先遷移?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Deleting a directory when clicked on a hyperlink with JAvascript.ASP.NET C#(單擊帶有 JAvascript.ASP.NET C# 的超鏈接時刪除目錄)
                  asp.net listview highlight row on click(asp.net listview 在單擊時突出顯示行)
                  Calling A Button OnClick from a function(從函數(shù)調(diào)用按鈕 OnClick)
                  ASP.net C# Gridview ButtonField onclick event(ASP.net C# Gridview ButtonField onclick 事件)
                  Adding OnClick event to ASP.NET control(將 OnClick 事件添加到 ASP.NET 控件)
                  Multiple submit Button click problem?(多個提交按鈕點(diǎn)擊問題?)
                3. <tfoot id='2cXiD'></tfoot>
                      <i id='2cXiD'><tr id='2cXiD'><dt id='2cXiD'><q id='2cXiD'><span id='2cXiD'><b id='2cXiD'><form id='2cXiD'><ins id='2cXiD'></ins><ul id='2cXiD'></ul><sub id='2cXiD'></sub></form><legend id='2cXiD'></legend><bdo id='2cXiD'><pre id='2cXiD'><center id='2cXiD'></center></pre></bdo></b><th id='2cXiD'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='2cXiD'><tfoot id='2cXiD'></tfoot><dl id='2cXiD'><fieldset id='2cXiD'></fieldset></dl></div>
                        <bdo id='2cXiD'></bdo><ul id='2cXiD'></ul>
                          <legend id='2cXiD'><style id='2cXiD'><dir id='2cXiD'><q id='2cXiD'></q></dir></style></legend>
                            <tbody id='2cXiD'></tbody>

                            <small id='2cXiD'></small><noframes id='2cXiD'>

                          1. 主站蜘蛛池模板: 欧美一区二区在线播放 | 伊人久久免费视频 | 91热爆在线观看 | 在线一区观看 | 九九热在线视频免费观看 | 国产成人99久久亚洲综合精品 | 日日摸天天添天天添破 | 亚洲国产一区二区三区在线观看 | 亚洲成人免费 | 久草电影网 | 欧美国产91| 久久69精品久久久久久久电影好 | 日韩视频在线免费观看 | 日本字幕在线观看 | jvid精品资源在线观看 | 成人免费日韩 | 欧美二区三区 | 成人视屏在线观看 | 午夜成人免费视频 | 91精品久久久久久久久中文字幕 | 日韩成人一区 | 久久精品欧美视频 | 欧美精品一区三区 | 日韩中文字幕在线视频观看 | 亚洲成人一区二区在线 | 国产重口老太伦 | 超碰在线免费 | 久久久久www| 精精国产xxxx视频在线野外 | 亚洲第一免费播放区 | 亚洲国产精品福利 | 久久久久亚洲精品国产 | 国产精品久久久久久婷婷天堂 | 一区二区三区不卡视频 | 欧美日韩国产精品一区 | 久久色视频 | 精品视频一区二区三区 | 中文精品视频 | 亚洲a在线观看 | 欧美色人| 国产精品久久av |