C# 布尔Linq查询

C# 布尔Linq查询,c#,linq,entity-framework,entity-framework-4,C#,Linq,Entity Framework,Entity Framework 4,是否有语法来运行Linq查询,如果找到记录,该查询将生成布尔值?基本上是这样想的 bool = table.field.contains(value) 下面的代码返回一个布尔值 table.Any(x=> x.fieldname== "test")

是否有语法来运行Linq查询,如果找到记录,该查询将生成布尔值?基本上是这样想的

 bool = table.field.contains(value)

下面的代码返回一个布尔值

table.Any(x=> x.fieldname== "test")