Skip to content

LINQ to Entities exception on search #2

@luposky

Description

@luposky

Sorry, I get an exception using the search box:

LINQ to Entities does not recognize the method 'System.String ToString()' method, and this method cannot be translated into a store expression

in Mvc.JQuery.Datatables.DynamicLinq.DynamicQueryable.Count(IQueryable source)
in Mvc.JQuery.Datatables.DataTablesFilter.FilterPagingSortingSearch(DataTablesParam dtParameters, IQueryable data, Int32& totalRecordsDisplay, Tuple`2[] columns)
in Mvc.JQuery.Datatables.DataTablesResult`2.GetResults(IQueryable q, DataTablesParam param, Tuple`2[] searchColumns)
in Mvc.JQuery.Datatables.DataTablesResult`2..ctor(IQueryable`1 q, DataTablesParam dataTableParam, Func`2 transform)
in Mvc.JQuery.Datatables.DataTablesResult.Create[T,TRes](IQueryable`1 q, DataTablesParam dataTableParam, Func`2 transform)
in LizardSetup.Controllers.ResultController.GetResults(DataTablesParam dataTableParam) in (myfile.cs)

I installed the package with nuget, followed the sample ... the grid is working (paging, sorting) but using the seach box give the exception ...

Any info ? Thanks,
Best regards,
Luca

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions