LINQ to Entities does not recognize the method 'System.DateTime ToDateTime(System.String)' method

System.Data.Objects.EntityFunctions和System.Data.Objects.SqlClient.SqlFunctions中的方法进行比较,如下

where System.Data.Objects.SqlClient.SqlFunctions.DateDiff("s",DateTime.Now,u.Time)>0

where System.Data.Objects.EntityFunctions.DiffSeconds(DateTime.Now,u.Time)>0

 

posted @ 2017-01-04 08:55  赤狐(zcm123)  阅读(1243)  评论(0编辑  收藏  举报