EF6.1.3 errors

edited January 16

We have been using Linqpad for a while and we use it as an essential tool in our company. However, recently Linqpad has begun to spit out errors for queries that run just fine if run in a 'normal' .NET application.

One bug, for example, is that it ignores Ignore(...) statements in EntityTypeConfigurations, we have to add NotMapped attributes just for LinqPad to work.

Another one we can't solve at the moment (making it unusable for us right now) is this one:
"Invalid column name 'Patient_Id'.Invalid column name 'Patient_Id1'.Invalid column name 'Patient_Id2'"
We have normal setup on a class 'Prescription' with an entity type configuration.

// Prescription.cs public int PatientId { get; set; } public virtual Patient Patient { get; set; } // PrescriptionConfiguration.cs HasRequired(p => p.Patient) .WithMany(p => p.Prescriptions) .HasForeignKey(p => p.PatientId);

How can we fix this?

Thanks for the great tool, we are usually happy premium customers :)


PS: Linqpad 5.26.01, EF 6.1.3 with built in CodeFirst provider.


  • Are you able to reproduce this problem with a very simple database and new Visual Studio project?

    create table Patient
    	ID int not null primary key,
    	Name varchar(30)
    create table Prescription
    	ID int not null primary key,
    	PatientID int null references Patient (ID),
    	Date datetime,
    	Description varchar(30)
  • edited February 7
    Yes, it will make easy to find the solution for your problem
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!