The argument types 'Edm.Decimal' and 'Edm.Double' are incompatible for this operation.

error you may run into while making queries in Linq-to-Entities

What this is indicating is that you are comparing a Decimal data type to a number that is not a Decimal. While it may look like it, this:
0.007 // is *not* a double in .Net land

// the proper form is this:
0.007M

So instead of this query:
var query = db.aTable.Where("it.Length = 0.01");
// make sure it is this instead:
var query = db.aTable.Where("it.Length = 0.01M");

Add comment

Loading