DateTime conversion by new Query()

Trying to figure it out for hours and hours. The simple filtration barks with
“Conversion failed when converting date and/or time from character string” from Microsoft.Data.SqlClient. The ChaseInks.Date property is “DateTime?”.

chaseInks = await SentimentPortalData.GetChaseInks(new Query() { Filter = $@"i => i.Date > @0 && i.Date < @1", FilterParameters = new object[] { DateTime.Now, DateTime.Now.AddDays(-7) }});

What is going on here? I use the same logic all over but THIS one does not work. All versions of EF are 6.0.0

In some cases EF might fail if the property is not described with the db type. For example:

Wonderful, thank you very much, it worked. A question, a I altered the model creation if will be wiped by my next model refreshing (I use Radzen Studio). Can not make Studio during model synchronization to describe the data types?

There is a partial method that can be used to extend the DbContext in a custom partial class that will not be overwritten:

Hello, I have the same issue but it doen´t work... any idea?

and in the context:

image

but unfortunatelly, I have this error:

Any idea about what is the issue?

Thanks.

According to the exception your column is varchar, not datetime.