title: table already exists exception when migrate DB using Entity Framework Core and SQLite
body: <p>I'm using EF Core and SQLite in UWP.  I tried to migrate  by calling DbContext.Database.Migrate() but I always get <code>Microsoft.Data.Sqlite.SqliteException: 'SQLite Error 1: 'table "Tags" already exists'.'</code>.  </p>
  
  <p>I'm sure that the table doesn't exist because I checked on bin/debug folder, there is no database file.  Even I check in wrong folder, there shouldn't have a problem doesn't it?<br>
  I've deleted Migrations folder many times but I don't think this is the cause of this exception.  </p>
  
  <p>This is DbContext code.  </p>
  
  <pre><code>public class AppDbContext : DbContext
  {
      public DbSet&lt;Word&gt; Words { get; set; }
      public DbSet&lt;WordMeaning&gt; WordMeanings { get; set; }
      public DbSet&lt;Tag&gt; Tags { get; set; }
      public DbSet&lt;WordTag&gt; WordTags { get; set; }
  
      protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
      {
          optionsBuilder.UseSqlite("Data Source=Vocabulary.db");
      }
  
      protected override void OnModelCreating(ModelBuilder modelBuilder)
      {
          // PK declaration
          modelBuilder.Entity&lt;Word&gt;()
              .HasKey(w =&gt; w.Text);
          modelBuilder.Entity&lt;WordMeaning&gt;()
              .HasKey(wm =&gt; new { wm.WordText, wm.WordClass });
          modelBuilder.Entity&lt;Tag&gt;()
              .HasKey(t =&gt; t.Name);
          modelBuilder.Entity&lt;WordTag&gt;()
              .HasKey(wt =&gt; new { wt.WordText, wt.TagName });
  
          // relation declaration
          modelBuilder.Entity&lt;Word&gt;()
              .HasMany(w =&gt; w.WordMeanings)
              .WithOne(wm =&gt; wm.Word)
              .HasForeignKey(wm =&gt; wm.WordText)
              .IsRequired()
              .OnDelete(DeleteBehavior.Cascade);
  
          modelBuilder.Entity&lt;WordTag&gt;()
              .HasOne(wt =&gt; wt.Tag)
              .WithMany(t =&gt; t.WordTag)
              .HasForeignKey(wt =&gt; wt.TagName);
          modelBuilder.Entity&lt;WordTag&gt;()
              .HasOne(wt =&gt; wt.Word)
              .WithMany(w =&gt; w.WordTag)
              .HasForeignKey(wt =&gt; wt.WordText);
      }
  }
  </code></pre>
  
  <p>and all of models code.  </p>
  
  <pre><code>public class Tag
  {
      public string Name { get; set; }
      public string Description { get; set; }
      public List&lt;WordTag&gt; WordTag { get; set; }
  }
  public class Word
  {
      public string Text { get; set; }
      public WordClass WordClasses { get; set; }
      public DateTime AddedDate { get; set; }
      public List&lt;WordMeaning&gt; WordMeanings { get; set; }
      public List&lt;WordTag&gt; WordTag { get; set; }
  }
  public class WordMeaning
  {
      public string WordText { get; set; }
      public string Definition { get; set; }
      public string Example { get; set; }
      public WordClass WordClass { get; set; }
      public Word Word { get; set; }
  }
  public class WordTag
  {
      public Word Word { get; set; }
      public Tag Tag { get; set; }
      public string WordText { get; set; }
      public string TagName { get; set; }
  }
  </code></pre>