473,387 Members | 1,561 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Loading Database Slow VB 2005

hi all,

i have problem on loading large database
i am using Firebird Database and VB.NET 2005

it seems really slow to load 10.000+ row on DataGrid

currently i use DataReader to open the database.

is there any method to make it more faster.

should I use DataSet or Data Adapter,
i am confuse what should i use

thx
Mar 8 '08 #1
8 1945
debasisdas
8,127 Expert 4TB
That is not the problem of database, but of front end.

But why you need to load 10000 + records in a grid ?
Mar 8 '08 #2
That is not the problem of database, but of front end.

But why you need to load 10000 + records in a grid ?


some times my client need to view data from 2005 to 2007
and i display it on grid.

if i not load to grid,where should i load it?

thx
Mar 8 '08 #3
daniel aristidou
491 256MB
some times my client need to view data from 2005 to 2007
and i display it on grid.

if i not load to grid,where should i load it?

thx
Well..


Instead you could only show 100 at a time in the data grid... create a next button and previous button to see next 100 and previous 100 records

Is your client gonna look forward to looking through 10k+ records.
Isnt a report better...(just something to consider)
Mar 9 '08 #4
Killer42
8,435 Expert 8TB
I agree, the slow load time is probably related more to the datagrid than the database. However, you can test this assumption by skipping the database and loading 10,000 test rows into your datagrid. You might use random values, or the same value repeated over and over, for example.
Mar 10 '08 #5
i understand
so the grid that takes long time to load

i just confuse what the reason ,cause my customer always complaint.

thx for the info
Mar 10 '08 #6
Killer42
8,435 Expert 8TB
Before looking too deeply into the "why" I believe you should ensure that you know the "what". We are all assuming that the problem is the datagrid. While I do agree this is probably the cause, you really should check it. A fundamental tenet of debugging is not to assume you know what the problem is, because you'll often be surprised.

Also, is the grid bound to the data source, or are you just using your code to load the information into it a row at a time, or what? In my experience, most grid controls seem to fair poorly as a data repository. Or to put it another way, they seem to be designed more for presentation purposes, formatting things for display, rather than for efficient storage of a large amount of data.

I'm not sure how much of this applies to the datagrid though - if I remember correctly, it more or less just puts a "face" on the data source. So the number of records may not have much effect on it.
Mar 10 '08 #7
Before looking too deeply into the "why" I believe you should ensure that you know the "what". We are all assuming that the problem is the datagrid. While I do agree this is probably the cause, you really should check it. A fundamental tenet of debugging is not to assume you know what the problem is, because you'll often be surprised.

Also, is the grid bound to the data source, or are you just using your code to load the information into it a row at a time, or what? In my experience, most grid controls seem to fair poorly as a data repository. Or to put it another way, they seem to be designed more for presentation purposes, formatting things for display, rather than for efficient storage of a large amount of data.

I'm not sure how much of this applies to the datagrid though - if I remember correctly, it's more or less just puts a "face" on the data source. So the number of records may not have much effect on it.
i use my code just to load to datagrid without bound it to data source,
i have try load 10000 row not from database, and it seems like the slow come from the grid.
but i confuse why another application can show it on grid fast, i look at application like Firebird Maestro,it shows the row faster and it using grid too.

thx for the information
Mar 27 '08 #8
Killer42
8,435 Expert 8TB
i use my code just to load to datagrid without bound it to data source,
i have try load 10000 row not from database, and it seems like the slow come from the grid.
Ok, thanks. I'm glad we've got that confirmed. Hopefully we can ignore the database side of things, then.

but i confuse why another application can show it on grid fast, i look at application like Firebird Maestro,it shows the row faster and it using grid too.
Ah, but is it the same grid control? There are big differences in the way some of them work.

Also, can you show us the code which populates the grid? Perhaps there's something inherently slow there. For example (I'm just making this up) if there are methods to load a row or a cell at a time, loading cell by cell might take a lot longer. Or perhaps your code is doing some very slow transformation of the data before loading it to each row of the grid.

There are all sorts of possibilities.

Keep in mind though, that it's often possible to make an application seem faster, even when it really isn't. This can be done by things like providing user feedback on the process rather than leaving the user to wonder what's going on. The "splash screen" is a prime example. By showing the user that something is happening, they make the load time of the application seem much shorter.

Another possibility might be to continue loading data in the background while the user interacts with the application, instead of making them wait until it's all loaded.

Or, you might be able to find a grid control which works faster.

Or keep the data in an array (or database) and only load enough of it into the grid to populate the screen. In fact, I've seen grid controls (many years ago, forget the details) which allow you to "bind" them to your own event procedure which provides the data. So you can treat the data control as though it is bound to a data source, but the source is your own code, which can be getting the data from anywhere you like (even creating it on the fly, or whatever).
Mar 28 '08 #9

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Philipp K. Janert, Ph.D. | last post by:
Dear All! I am trying to load a relatively large table (about 1 Million rows) into an sqlite table, which is kept in memory. The load process is very slow - on the order of 15 minutes or so. ...
4
by: Adrian MacNair | last post by:
Hi, I created an image gallery which displays 63 images in a slideshow. The problem is that the show was slow because each image loaded one at a time during the show. No problem right? I just...
1
by: Fabricio Tofoli | last post by:
Hello all, I have a simple ASP.NET project that displays the contents of a MySql database table in the web page. All pages are extremelly slow, and not only the first time you access them, it's...
3
by: aspnet guy | last post by:
my asp.net website is slow at my work machine but very fast at home. My work uses a firewall. Can that slow down the loading of web forms? are there any "common" things I can try to get it to...
2
by: Mark | last post by:
Hi, in VS 2005 suddenly a program that used to start in the debugger within a couple seconds now takes a couple minutes to start. The problem appears to be thrashing about constanting loading...
10
by: eholz1 | last post by:
Hello Members, I am setting up a photo website. I have decided to use PHP and MySQL. I can load jpeg files into the table (medium blob, or even longtext) and get the image(s) to display without...
5
Coldfire
by: Coldfire | last post by:
I am having problem with slow crystal report loading plus slow dataadapter.fill method here is my code string SelectCmd = "SELECT * FROM EnterInstituteInformation WHERE...
5
by: =?Utf-8?B?V2FubmFiZQ==?= | last post by:
We have a page that is loading very slow. There is not a lot of data, not a lot of users are connected at the same time and the page does not produce an error, so I am not sure where to start to...
1
by: rshivaraman | last post by:
Hi All: I need to make my database unavailable when i am loading the db. This happens daily and the db is not connected to any online app, to make the app unavailable. It is queried thru an...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.