数据集太慢了! [英] Dataset is too slow!

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

问题描述

大家好!
我创建了基于SQL Server数据库的新应用程序汽车档案"
即时通讯使用数据集和拖放"方法. 数据集包含数据库的所有表格.
这对程序的速度有影响吗?
我注意到表格太慢,需要2-3秒.
另一个问题:如果我为每个表都制作一个单独的数据集会更好吗?

感谢很多
Ahmed Abu aziz

Hello every body!
Im creating my new application "car archive" which based on sql server database
im using dataset and ''drag and drop'' mathod . the dataset includes all tabeles of the data base.
did this effect on the speed of the program?
i noteced that the form is too slow, it takes 2-3 seconds.
the other question : Does it better if i make a seperate datasets for each table or not?

Thanks Alot
Ahmed Abu aziz

推荐答案



通常,我创建的数据集中具有相似的表或具有相似的功能.除非您有数百张表,否则不会出现速度问题.

但是,VS使用拖放方法,将创建一个没有过滤器的默认选择语句.(即,带回表中的所有内容.)
为了更快,您将需要向适配器添加另一个查询并指定要返回的内容(在某处的where子句中放置)

如果您使用的是ObjectDatasource,请指定新查询,然后开始执行,加快加载速度.

希望这对您有帮助...
Hi,

I generally create datasets that have similar tables in them or that do a similar job. Unless you have hundreds of tables there should not be a speed problem.

However using the drag and drop method, VS creates a default select statement that has no filters.(ie bring back everything in the table.)
To make it quicker you will need to add another query to the adapter and specify what you want returned (put in a where clause somewhere)

If you are using the ObjectDatasource, then specify the new query, and there you go, faster loads.

Hope this helps...


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

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