tags:

views:

17

answers:

1

Hi All,

I am using and EntityDateSource and I add where condition to filter the data at runtime and then bind the grid to the dataSource, but I am getting following error:-

The argument types 'Edm.DateTime' and 'Edm.String' are incompatible for this operation.

Search condition looks like this:-

it.[MyDate]='8/13/2010 00:00:00'

Any Idea how this can be fixed ?

A: 

EntityDataSource.Where uses EnttiySQL sytanx. The date time literals need to be specified in YYYY-MM-DD HH:MM - see the documentation.

In short, use syntax such as it.[MyDate]='2010-13-8 00:00' and you should be ok.

VinayC