Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

186
Views
Creating a Primary Key Entity Framework Code First

Hi I have a table (InspectionItemViolationCategories) that's being created as below using Entity Framework Code First, but now the situation came that I need to remove the unique requirement of both column combination and need to add a Primary Key with identity, any help please?

    modelBuilder.Entity<InspectionItem>()
        .HasMany(i => i.InspectionItemCategory).WithMany().Map(m =>
    {
        m.MapLeftKey("InspectionItemId");
        m.MapRightKey("ViolationTypeId");
        m.ToTable("InspectionItemViolationCategories");
    });

There is no class exists with name InspectionItemViolationCategory as an entity, so need help

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!