linq技巧-位操作查询

 linq:

1 var results = from o in objects
2     where (o.enumProperty & enumValue) != 0
3     select o;

 esql:

1 select value o from objects as o
2     where BitWiseAnd(o.enumProperty, @enumValue) <> 0

 

posted @ 2017-03-24 18:47  woolhoo  阅读(209)  评论(0编辑  收藏  举报