如何更快地供访问,然后搜索更新超过100k的数据?

发布于 2025-01-27 03:25:41 字数 297 浏览 3 评论 0原文

我有用于后台作业的控制台应用程序。 该应用程序会喜欢这样,

  1. 从数据库中获取可以调用表A(具有100K数据)的位置的数据(有100K数据)和可变的位置
  2. ,然后位置数据将在数据库中的另一个表中搜索,我们可以调用表B,并计算多少 然后,他们已经
  3. 更新数据库表中的数据计数foreach位置
  4. 后,所有完成的位置将更新数据库表C进行摘要。

我已经制作了.NET核心。所有顺序需要很长时间。 我在表A中的数据将增加超过500k。

也许还有另一种方法可以更快或使用其他技术

i have console app for background job.
the app will do like this,

  1. get data from database for the location we can call table A(have 100k data) and place to variable
  2. then foreach data of location will search in another table in database we can call table B, and counting how many data they have
  3. then update the count of data in database table A foreach location
  4. after all that is done will update database table c for the summary.

i already make in .net core. and its takes long time for all of the sequence.
and my data in table A will add more than 500k.

maybe there is another way to make faster, or using another tech

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文