快速检索数据 [英] Speedly retrieve data

查看:129
本文介绍了快速检索数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,我的朋友们.

我正在使用"Windows CE 6.0"对POS设备的商店管理进行编程.这些设备太低了.这些设备中的ram是硬的:-(.
现在,我有15000条记录和wana select记录,其中"CategoryCode列"值为"445500"(这些记录的计数是50).
我使用不同的方法来选择数据:

1. SQL CE3.0
对于连接到银行获得4sec
执行WHERE命令获得8秒

2.我创建一个库( DotTxt [

Hello my friends.

I''m programming a store management for POS device with "Windows CE 6.0". These device are so low. The ram in these device is the hard :-(.
Now, I have 15000 record and wana select records where the "CategoryCode column" value is ''445500'' (Count of these record is 50).
I use different ways to select the data:

1. SQL CE3.0
For connect to bank get 4sec
For execute WHERE command get 8sec

2. I create a library (DotTxt[^]) that work with text file.
For execute WHERE command get 6sec

3. Using XML
For open XML document get 32sec
For execute WHERE command get 1sec

4. Using DataTable (that fill with a text file)
For retrieve lines in DataTable get 13sec
For excute WHERE command (select) get 3sec

Each of these ways have an problem. I bold them.

Please help me to work with a better way for better speed.

Thanks your helps.

推荐答案


您可以使用SQL数据分页从数据库级别获取数据.
使用DataReader可以最大程度地减少应用程序级别的时间.

请参阅下面的链接
> http://stackoverflow.com/questions/1213144/data-paging- in-sql-server-ce-compact-edition [ ^ ]
Hi,
You can use SQL data paging for fetch the data from DB level.
Minimize the time in application level use DataReader.

refer below link
http://stackoverflow.com/questions/1213144/data-paging-in-sql-server-ce-compact-edition[^]


为提高速度,请使用linq-sql进行数据访问
For increasing speed use linq-sql to get data access


这篇关于快速检索数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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