我有以下查询。在其中,我正在执行 Take(2100) 以避免施加 2100 rpc 限制。
var query =
from result in staging_sparc_sophis_trade.AsQueryable()
where deals.Take(2100).Contains(result.TRADE_ID)
select new traded_product()
{
Deal = result.TRADE_ID,
CostCentre = result.FTP_COSTCTR,
InvolvedPartyId = R_GEN_002(result.hsbc_source_system_instance, "", result.CNPTY_ACRONYM
};
我想知道的是,有没有一种方法可以删除 Take(2100) 部分并将其替换为 Deal 行中的 lambda 语句,以检查交易是否在我正在搜索的列表(交易)中?