Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

select distinct linq mvc

public static IQueryable<ProdType> GetDistinctProdType(
    this IQueryable<ProdInfo> query,
    int categoryId)
{
    return (from p in query
            where p.CatID == categoryId
            select p.Type).Distinct();
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #select #distinct #linq #mvc
ADD COMMENT
Topic
Name
6+2 =