当前位置:网站首页>[bug] the element in C iqueryable cannot change its value
[bug] the element in C iqueryable cannot change its value
2022-06-23 23:52:00 【I left my life to work】
Code
The code has been changed , It's just an excerpt , But it's the same
var sysPersonnels=SysPersonnelRepository.FindAsIQueryable(f => f.IsDeleted == 1 && f.SyncWithDhDeletedTime == null).IgnoreQueryFilters();
sysPersonnels= personel_Erp.Where(f => f.PersonnelName.Contains(" test ")).Take(2);
foreach (SysPersonnel personnel in sysPersonnels)
{
personnel.SyncWithDhDeletedTime = DateTime.Now;
}
//foreach End sysPersonnels Inside SysPersonnel Of SyncWithDhDeletedTime Still no value The following updates will not work
SysPersonnelRepository.UpdateRange(sysPersonnels, x => new {
x.SyncWithDhDeletedTime
});
reason
Change to List After that
var personel_Erp=SysPersonnelRepository.FindAsIQueryable(f => f.IsDeleted == 1 && f.SyncWithDhDeletedTime == null).IgnoreQueryFilters().ToList();
personel_Erp= personel_Erp.Where(f => f.PersonnelName.Contains(" test ")).Take(2).ToList();
I don't know why , Also look at the big god pointing a thing or two
There are similar problems on the Internet that I don't quite understand : Why can't it be changed IQueryable The attributes of the elements inside ?
边栏推荐
- Docker Deployment redis
- 2022山东健博会,济南国际大健康产业博览会,中国营养健康展
- 格林公式挖洞法中内曲线顺时针的直观解释
- Improvement of DC power distribution with open hall current sensor
- 文言文能编程???
- This high imitation millet mall project is amazing
- Cross domain issues of the new version of Google browser
- ACM. Hj89 24 point operation ●●●
- What is the production process of enterprise website? How long does it take to design and build a website?
- 2018/GAN:Self-Attention Generative Adversarial Networks自我注意生成对抗网络
猜你喜欢

一款高仿腾讯漫画的漫画阅读类 APP

Innovative lampblack supervision in the management measures for the prevention and control of lampblack pollution in Deyang catering service industry (Draft for comments)

EF Core中的三类事务(SaveChanges、DbContextTransaction、TransactionScope)

Task queue of laravel

Le roman du drapeau de l'imitation haute version flutter, apprenez - le

Tupu software intelligent wind power: operation and maintenance of digital twin 3D wind turbine intelligent equipment

Flux in three dimensional vector field

List<? extends T>和List<?super T>区别

不容错过 | 华为内部资料--成功的项目管理PPT(123页)

开口式霍尔电流传感器助力直流配电改造
随机推荐
1004. 最大连续1的个数 III ●●
CVPR2019/图像翻译:TransGaGa: Geometry-Aware Unsupervised Image-to-Image Translation几何感知的无监督图像到图像的翻译
Avoid confusion when switching between arouter components
What is the same origin policy?
Math. Max() method obtains the maximum value in the array and returns Nan problem analysis
工作中一些常用的工具函数
Thinking (87): Protocol encryption and compression
The group procurement management system of daily chemical supplies industry changes the traditional procurement mode and reduces the procurement cost
How to achieve the turning effect of wechat video recording?
PMP考试相关计算公式汇总!考前必看
图扑软件智慧风电:数字孪生 3D 风机智能设备运维
高仿書旗小說 Flutter 版,學起來
文言文能编程???
Visual explanation of clockwise inner curve in Green's formula hole digging method
2018/GAN:Self-Attention Generative Adversarial Networks自我注意生成对抗网络
2022 information security engineer examination knowledge point: access control
电子元器件行业B2B交易管理系统:提升数据化驱动能力,促进企业销售业绩增长
2022年信息安全工程師考試知識點:訪問控制
微信录制视频转圈效果如何实现?
网站ssl证书