views:

94

answers:

0

ClassABC is not a valid metadata type for type filtering operations. Type filtering is only valid on entity types and complex types.

.Search(columns_to_search, parseSearchString(SearchValue))

I got above error when i use in my entity framework query.

(from cp in ctx.ABCSet
                         select new
                         {
                             ClientApplicationID = cp.ClientApplicationID,
                             Application_Name = cp.ApplicationName


                         }
                        )
              .Search(columns_to_search, parseSearchString(SearchValue))

              .OrderBy("it." + sortField + " " + sortOrder)           
              .Skip((pageNumber - 1) * pageSize)
              .Take(pageSize).OfType<ClientApplicationUnit>().ToList();

My object to use generic process to query for each column for a string value.