Solved

Paradox: filters versus queries

Posted on 2002-04-13
4
228 Views
Last Modified: 2010-04-04
Hi all,

Is there a significant speed difference in filtering
a paradox table versus defining a query, using the BDE
and native paradox driver?

I'm wondering, as I have been using filtering extensively, but it really seems to start bogging down pretty quickly.

Any discussion appreciated.
0
Comment
Question by:oneeye
4 Comments
 
LVL 15

Accepted Solution

by:
simonet earned 100 total points
ID: 6939631
Yes... queries are always faster.

This is because Delphi has to create a query from the TTable component, and that itself is already some overhead to the application. Now, if there's a filter, then it's even more work.

If everything is already in a query, Delphi simply has to submit the query to the BDE and wait for the results. No overheads, no nothing.


Alex
0
 
LVL 27

Expert Comment

by:kretzschmar
ID: 6939785
depends if there is an index on the filtered field,
but usual a query is faster than a filter

meikl ;-)
0
 
LVL 9

Expert Comment

by:ITugay
ID: 6939880
Hi oneeye!

I agree with Alex and meikl, but there is another side of medal:

filtering works faster in case you open table once and then apply different filters few times. It similar to caching mechanizm, it works slow first time, but fast in further usage of the same data. So, it is depend from what you are going to do.

------
Igor.
0
 

Author Comment

by:oneeye
ID: 6940503
Okay,

Less overhead is good, I'll try a few queries and see if I see a performance improvement. Now I just have to review SQL.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
drawing animated level bar based on numbers 3 103
Dynamically Created Query 3 62
DBGrid or StringGrid ? 6 103
enhance the following code 3 37
This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question