BDE alternatives: Who's faster?

         This article presents the result of speed characteristics investigations; BDE alternatives are compared to Borland Paradox with BDE. Diagram 1 presents the results of all existing speed tests for the products mentioned above. Diagram 2 presents reading speed test results, and Diagram 3 presents writing tests results. Comparison of all these products by searching speed when searching for all the records matching the specified search criteria, is presented at Diagram 4 (find first and find next results are compared for equality on 5 conditions. They are: Integer, Sting, Date/Time, Integer & String & DateTime, String with partial compare). Diagram 5 shows searching speed when searching for the single record matching the search criteria of the 'equiality' type (Locate by the same five conditions). Diagram 6 presents the result of comparison of the same DB engines by filtering speed (the same five conditions). Diagram 7 shows the results of comparison by BLOB fields processing speed.


BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

BDE alternatives: Who's faster?

         Testing had been executed on a table containing 10 000 records and including Integer/DateTime/String fields filled with data obtained by means of the standard program random-number generator, Randomize. For testing search engines after generating data, a random sequence of 1000 records is chosen, which is 10% of the whole number of records. This sequence of different records is then replaced with another sequence consisting of the same record repeatedly duplicated. This operation is performed for executing FindNext and filtering search.

         Let us now describe the tests themselves. The very first group of tests includes basic operations with tables, such as adding records, updating records, deleting records, reading table to memory (it is used for emulating direct operating with tables, without using DBGrid, DBNavigator and their analogues), as well as moving the cursor to a defined position. TTable uses the following methods for implementation of these operations: Insert, Edit, Post, Delete, First, Next, MoveBy. All the data is prepared in advance and is stored in dynamic arrays ids, ints, dates. Time measurement is the same for all the tests and is realized by means of Win API function GetTickCount, for this function measures time in milliseconds in contrast to Now function. Execution times for all such blocks are summed and then averaged out by test passes number (simple average of a single pass time is calculated). We pass through each test 10 times. The measurements results are given in Table 1.


Table 1. Tests passing time, sec.

DB Engine

Paradox 7.0

DBISAM

EasyTable

MiniTable

TurboDB

TinyDB

Version

BDE 5.1

2.09

2.0

5.0

3.2

2.4

Release date

06/21/99

05/27/01

06/01/01

02/06/00

04/31/01

05/07/01

Autor

Borland

Elevate Software

AidAim Software

 Unley  Software

dataWeb GmbH

DayDream Software

Basic I/O operations

61.368

2,035.634

21.810

211.564

3,452.947

3,376.711

Reading

51.679

2,000.326

0.643

167.935

3,347.995

6.268

Read records

1.034

0.811

0.638

0.685

1.100

3.205

Navigate records

50.645

1,999.515

0.005

167.250

3,346.895

3.063

Writing

9.689

35.308

21.167

43.629

104.952

3,370.443

Insert records

4.163

13.811

6.221

14.611

50.434

1,173.703

Edit records

2.339

5.996

4.082

5.593

9.352

2,130.426

Delete records

3.187

15.501

10.864

23.425

45.166

66.314

Searching by Find

400.136

295.770

12.406

10,518.236

Failed!

Failed!

FindFirst integer

5.915

39.513

1.817

764.795

Error

510.567

FindFirst string

102.944

47.414

2.190

1,042.525

Error

899.207

FindFirst datetime

6.993

48.052

2.114

820.494

Error

Error

FindFirst all fields

108.660

48.989

4.225

1,636.344

Error

Error

FindFirst substring

101.860

48.410

1.920

990.140

Error

928.571

 

0.000

0.000

0.000

0.000

Error

0.000

FindNext integer

0.080

3.887

0.015

759.315

Error

1.566

FindNext string

0.585

16.972

0.035

1,057.160

Error

2.028

FindNext datetime

0.120

6.014

0.015

819.205

Error

Error

FindNext all fields

0.410

19.845

0.040

1,650.833

Error

Error

FindNext substring

0.295

16.674

0.035

977.425

Error

2.196

Searching by Locate

44.715

141.446

1.238

135.841

Failed!

1,807.834

Locate integer

5.145

40.434

0.130

0.608

1,393.639

5.099

Locate string

0.504

2.047

0.160

0.654

Error

5.974

Locate datetime

6.851

46.998

0.180

133.220

1,478.611

5.276

Locate all fields

31.700

49.857

0.598

0.696

Error

1,782.780

Locate substring

0.515

2.110

0.170

0.663

Error

8.705

Filtering

1.080

14.793

0.065

6.215

Failed!

Failed!

Filter integer

0.080

2.950

0.005

0.945

2.239

1.653

Filter string

0.130

2.958

0.020

1.265

Error

2.124

Filter date

0.070

2.965

0.000

1.025

Error

Error

Filter all fields

0.530

3.005

0.015

1.860

Error

Error

Filter substring

0.270

2.915

0.025

1.120

Error

1.835

BLOB processing

400.136

446.397

233.674

36,615.899

946.996

3,159.677

Insert BLOB Data  

216.186

110.874

111.218

256.757

374.595

2,520.170

Read BLOB Data   

96.425

104.195

103.122

118.016

190.057

60.420

Delete BLOB Data

87.525

231.328

19.334

36,241.126

382.344

579.087

All tests

835.161

2,934.040

269.193

47,487.755

Failed!

Failed!


         Well, let us now review it all.
         1. EasyTable by AidAim Software is an undisputable leader in searching and I/O operations speed.
         2. Paradox + BDE (native driver, supplied with the delivery set) by Borland Software Corporation shows quite good results in speed. This combination even exceeds a bit EasyTable, our tests leader, in data writing speed; but even if writing operations sort with reading operations as 1:1 (as for real applications, this ratio may be much greater), EasyTable still wins over Paradox in I/O operations speed (it is almost 3 times faster). Here we must say, that this is the only system of all the considered, which uses BDE; this feature sometimes becomes inconvenient due to the large size of the compiled code. All the other tested systems are 5 to 10 times more compact.
         3. Pity, but such a well-known and widely advertised in the Internet as a high-speed DB engine system as DBISAM did not show high results in speed and lost before the leader in the sum of all the tests, having appeared over 10 times slower then EasyTable. In the input-output time it remains behind the EasyTable, being almost 100 times slower! Moreover, DBISAM is equipped with a very slow searching engine. In the Find category EasyTable, our leader, is over 20 times faster than DBISAM. We should note that Find next is executed especially slowly; for example, in complex inquiry (Find next all fields) EasyTable is almost 500 (!!!) times faster. DBISAM is almost 100 times slower than EasyTable in Locate and over 200 times - in filtering. Hence, to our opinion the testing results cited by DBISAM as a confirmation of their high results in speed, are not quite correct, for the testing principles are far from being perfect, as well as the way to produce the result (I/O times are not measured; single operation time being measured is comparable to the measurements precision itself; only special operations are measured; the source code given is beyond compilation and so it may not be used for testing ), the products assortment for testing is very tendentious.
         4. The slowest of all DB engines that passed our tests successfully is MiniTable. EasyTable is 176 times faster than it is! It looks like this product's perfection finally stopped over a year ago.
         5. Obviously bad results shown by TurboDB became an unpleasant surprise. In I/O operations EasyTable is over 150 times faster than TurboDB is. Moreover, this DB engine appeared unable to pass our testings due to errors that arosed with testing searching (Locate) and filtering (due to bugs with strings and dates). TurboDB doesn't have Find first / Find next featuers at all. Even in those rare cases when we managed to measure its searching and filtering characteristics, TurboDB proved to be the most slow system: EasyTable is 10,000 (!!!) times faster in searching by Locate and almost 500 times faster in filtering. So, tests had really shown that TurboDB isn't worse its "quick" name - let this trademark never mislead anyone else!
         6. TinyDB also appeared unable to pass testings due to errors in testing Find and filtering. Moreover, like TurboDB it showed very low speed as in the I/O operations, so as in the searching engine testing, too.
         7. We had also tested some other systems, but their results proved to be even worse than those of this review's leaders; over this, we found some of those products worthless mentioning in this article due to some of their features.
         To sum up, we must say that EasyTable proved to be the fastest to date DB engine. TurboDB and TinyDB are not recommended to use due to multiple errors in their searching algorithms. Moreover, these two systems seem to be absolutely hopeless in achieving high performance results.
         Note. When reviewing the summary productivity of the tested DB engines we supposed that all the operations take the same part in the total system's productivity; surely, you'll never meet such a situation in real applications. Nevertheless, having received the above-mentioned results and having analysed the real frequency of using this or that operation in your application on the example of a typical task, you may learn, which of the systems listed above will be faster, and how much faster, for your particular case. However, basing on the results given in the present article, EasyTable by AidAim Software will probably become the fastest system in your case, too.

         We give source code of the testing program for each DB engine. You may also download compiled testing programs with sources. Due to some distinctions of functions realization in different programs, we used different testing programs for any of the products being tested, using the same measurement principles. Any comer may carry out the same measurements and make sure in reliability of the results presented here. You may also be free in testing the products presented here and change the measurements principles in order to obtain, for example, the dependency of DB engine(s) operating speed on the number of records. Furthermore, you may change any of the programs presented here in order to test any other product. In any case, with any publishing of any investigations using the materials presented here (including program(s) for measurements) or the measurement principles, you must needs refer to the author and the article itself.

Raymond Mortimer.