How to force migrations to a DB if some tables already exist in Django? : <p>I have a Python/Django proyect. Due to some rolls back, and other mixed stuff we ended up in a kind of odd scenario.</p>

<p>The current scenario is like this:</p>

<ul>
<li>DB has the correct tables</li>
<li>DB can't be rolled back or dropped</li>
<li><p>Code is up to date</p></li>
<li><p>Migrations folder is <strong><em>behind</em></strong> the DB by one or two migrations. (These migrations were applied from somewhere else and that "somewhere else" doesn't exist anymore)</p></li>
<li><p>I add and alter some models</p></li>
<li>I run <em>makemigrations</em></li>
<li>New migrations are created, but it's a mix of new tables and some tables that already exist in the DB.</li>
<li>If I run <em>migrate</em> it will complain that some of the tables that I'm trying to create already exist.</li>
</ul>

<p>What I need:</p>

<p>To be able to run the migrations and kind of "ignore" the existing tables and apply the new ones. Or any alternative way to achieve this.</p>

<p>Is that possible?</p>
