我想从具有1,000,000条记录问题的sql server中访问数据库表吗? [英] I want to access a database table from sql server which is having 1,000,000 records problem?

查看:132
本文介绍了我想从具有1,000,000条记录问题的sql server中访问数据库表吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从具有1,000,000条记录的sql server中访问数据库表.我希望将应用程序中的所有记录进行比较.当我尝试访问数据时,它给出了system.OutOfmemory异常.请建议我如何克服这个问题.迫切
还建议是否还有其他方法可以改善访问性能

温馨的问候

shivanand Nagarabetta [电子邮件删除]

I want to access a database table from sql server which is having 1,000,000 records. I want all the records in my application to compare. When i tried to access the data it is giving system.OutOfmemory exception. Please suggest me how to overcome this problem. its urgent
also suggest if there are any other methods to improve the performance of access

Warm Regards

shivanand Nagarabetta[Email removed]

推荐答案

仅紧急解决方案,可能在以后失败:)

如果您有一个数字主变量(不是很重要,但它使它变得更容易),则可以从数据库中逐包读取(1 ... 1000、1001 ... 2000,...),并将其保存在内存中(....).因此,至少查询组件不应以OutOfMemory结尾.

问候
Only emergency solution with the possibility to fail on a later stage :)

In case you have a numeric primary (not really important, but it makes it easier) you can read in package by package (1...1000, 1001...2000, ...) from the DB and hold it in Memory (….). So at least the query component should not end with OutOfMemory.

Regards


这篇关于我想从具有1,000,000条记录问题的sql server中访问数据库表吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆