My entity has a field called `Value`. This field is a `string`, but it hold `int` and `DateTime` values also.

My regular query is something like 

```
SELECT * FROM tableA 
WHERE entityType=@eID and CAST(value as int/datetime/varchar)==@value

```

How can I make **EF** generate a query with a cast?

Edit: create suggestion on [uservoice](http://data.uservoice.com/forums/72025-entity-framework-feature-suggestions/suggestions/6983885-convert-toint)