473,396 Members | 2,013 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,396 software developers and data experts.

Weird problem in forms?

I have a problem which I do not understand........................

I have a split database. Tables in the backend on a networkdrive, all
other in frontend placed in %temp%

I have this form [form1] that is based on a query [main query]. This
query consists of one table [table1] and two queries [subquery1 &
subquery2], both of them joined to the table. It takes about three
seconds to load [main query].

To improve performance I put the results of [main query] in [table2].
I did that by copying [main query 1] to a create table query so that
fieldnames etc remained the same.
I put some indexes in the table on the numeric fields that are used for
filtering and searching.
I made a query [main query 2] (Select * from table2) that runs in less
then a second. Perfect!

Now I based [form1] on [main query 2].

Shocked I saw how the performance of the form actually dropped instead
of speeding up....

The form loads a bit faster then it did when based on [main query 2]
but the conditional formatting on the form is really slow, one can
actually see line after line being formatted (4 fields get a different
backcolor based on the value within that field). When scrolling, lines
get formatted as they are visible on the screen, this really reduces
speed when scrolling through the page (2623 records)

When loading THE SAME form based on [main query 1] loading the forms
takes about half a second longer but conditional formatting is done
within a second for the whole! form.

so, to be short, [main query 2] is about three times as fast as [main
query 2].
Still a form based on [main query 2] is slower then a form based on
[main query 1] even though they contain exactly the same fields en
fieldnames.

Is there anyone who knows how this can happen or who can tell me what
to look for?

Greetings, Henro

Jan 11 '07 #1
1 1401
Found it! It was just a matter of indexing: that had not been done on
the new table at all!
On 11 jan, 12:04, "Henrootje" <Hen...@gmail.comwrote:
I have a problem which I do not understand........................

I have a split database. Tables in the backend on a networkdrive, all
other in frontend placed in %temp%

I have this form [form1] that is based on a query [main query]. This
query consists of one table [table1] and two queries [subquery1 &
subquery2], both of them joined to the table. It takes about three
seconds to load [main query].

To improve performance I put the results of [main query] in [table2].
I did that by copying [main query 1] to a create table query so that
fieldnames etc remained the same.
I put some indexes in the table on the numeric fields that are used for
filtering and searching.
I made a query [main query 2] (Select * from table2) that runs in less
then a second. Perfect!

Now I based [form1] on [main query 2].

Shocked I saw how the performance of the form actually dropped instead
of speeding up....

The form loads a bit faster then it did when based on [main query 2]
but the conditional formatting on the form is really slow, one can
actually see line after line being formatted (4 fields get a different
backcolor based on the value within that field). When scrolling, lines
get formatted as they are visible on the screen, this really reduces
speed when scrolling through the page (2623 records)

When loading THE SAME form based on [main query 1] loading the forms
takes about half a second longer but conditional formatting is done
within a second for the whole! form.

so, to be short, [main query 2] is about three times as fast as [main
query 2].
Still a form based on [main query 2] is slower then a form based on
[main query 1] even though they contain exactly the same fields en
fieldnames.

Is there anyone who knows how this can happen or who can tell me what
to look for?

Greetings, Henro

Mar 9 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Ryan Park | last post by:
Hi, //SITUATION I got a panel control that hold a certain position on a form. Every controls or UIs are on this panel. At certain situation, I called dispose() method of this panel control...
0
by: Deutsche Dogge | last post by:
Hi. I'M having a weird problem with addign menuitems to a menu dynamically on the popup event of the menuitem containing the container of the menuitems i wanna add (tools -> external -> {list of...
3
by: ThunderMusic | last post by:
Hi, I'm trying to have a MSN Messenger like form/app closing behavior. When I click on the X button, I only want the form to disappear and when I double-click on the notify icon or right-click...
8
by: Deano | last post by:
Here's the code; Private Sub txtTeachName_LostFocus() If IsNull(Me.txtName) Then 'line A Forms!frmMainform!frmSubform.Locked = True GoTo Exit_txtName Else 'line B...
2
by: Christian Kreimer | last post by:
Hi I created an C# windows forms application that holds a user control. The user control itself is an editor for geographical information systems and is based on an ActiveX Library for providing...
3
by: Me | last post by:
I'm getting a NullReferenceException in Unknown Module when I follow the below steps to create a simple NotifyIcon app that creates the context menu on the fly(see a little analysis after the...
4
by: BradC | last post by:
I have an MDI parent application with several forms inside it. As the user switches between forms, I am forcing a maximize to keep it filling up the parent window. When the user has one...
1
by: Andrew K | last post by:
Hi, This is a problem I noticed in one of my applications the other day and can't figure out how to fix. In the attached code I have 2 forms. The form named form1 is the MDI container, form2...
10
by: Charles Law | last post by:
For some reason, when I click the X to close my MDI parent form, the action appears to be re-directed to one of the MDI child forms, and the parent remains open. I am then unable to close the...
2
by: Flack | last post by:
I have a DataGrid and a DataTable. When my form loads I create the DataTable with the appropriate columns and use it for the DataGrids.DataSource. Later on in my app, I alter the DataTable: ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.