Q:

Map names for generated relationship tables in EF code first

I'm giving Code first a try and I have the requirement of a prefix of (all) my tables in db.
In my DbContext I have these entities:
    public DbSet<Person> People { get; set; }
    public DbSet<Department> Departments { get; set; }

I can successfully map table names for my entities by overriding:
    protected override void OnModelCreating(DbModelBuilder modelBuilder)
    {
        modelBuilder.Entity<Person>().ToTable("w_people");
        modelBuilder.Entity<Department>().ToTable("w_departments");
    }

However for tables that created that don't directly map to a table I can't figure out to prefix.
In my example people can belong to many departments so a "non-entity" table is created by EF. (I'm a EF noob so these tables probably have a fancy name) So in my db I get three tables:
w_people
w_departments
PersonsDepartments

The PersonsDepartments table is what I'm after. How can I prefix these generated tables or change name/mapping after generation?
TIA

A:

I have solved this:
modelBuilder.Entity<Person>().HasMany(p => p.Departments)
               .WithMany(d => d.People)
               .Map(mc => mc.ToTable("w_peopledepartments"));

