FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Is CDX better than NTX?
Posts: 1387
Joined: Fri May 23, 2008 01:33 PM
Is CDX better than NTX?
Posted: Sat Oct 11, 2008 12:15 PM

Hi,

As my subject, should I change my databases to CDX Index?

If yes, Is there any easy method to convert my programs?

I suppose that xBrowse recognize the indexes to change sort order in CDX. Is it true?

Thanks,

Regards,



Hakan ONEMLI



Harbour & MSVC 2022 & FWH 23.06
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
NTX or CDX
Posted: Sat Oct 11, 2008 01:35 PM

Hello,

To use CDX instead of NTX, is the better option.

If you open a database, the CDX-Index is opend as well.

I use ORDCREATE and ORDCONDSET

Sample 1 :

Old Style :

Index on upper(archiv_no) + DESCEND(str(n_year) + str(n_month)) to "FAKT1" UNIQUE

New Style :
( .T. included in the Index-array means UNIQUE )


ORDCREATE( ,"FAKT1","LOWER(archiv_no) + DESCEND(str(n_year) + STR(n_month)", ;
{|| LOWER(archiv_no) + DESCEND(str(n_year) + STR(n_month) } , .T. )

-----------------------------------------------------------

Sample 2 :
// Index-direction Down = .T.

Old Style

Index on DESCEND(str(n_year) + invoice_no + archiv_nr) ;
to "FAKT3" UNIQUE

New Style

ORDCONDSET( , , , , , , , , , , .T. ) // DESCEND
ORDCREATE( ,"FAKT3","STR(n_year) + invoice_no + archiv_no", ;
{|| STR(n_year) + invoice_no + archiv_no } , .T. ) // UNIQUE

Be careful, to use soemething like : UPPER(Name)
In case of < ร–ร„รœ > at the beginning of the name, it doesn' work.
You have to use LOWER !!!!

Regards
Uwe :lol:

Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Is CDX better than NTX?
Posted: Sat Oct 11, 2008 06:07 PM

Hakan,

> I suppose that xBrowse recognize the indexes to change sort order in CDX. Is it true?

Yes, XBrowse fully supports CDXs indexes.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1467
Joined: Mon Oct 10, 2005 11:26 AM
Is CDX better than NTX?
Posted: Sat Oct 11, 2008 08:29 PM

Hello,

There is still another reason why CDX is better than NTX.

For each NTX-index of a file, a filehandle is opened.

If you have a file with 5 NTX-indexes, you have 6 filehandles opened.

In case of CDX, only one filehandle is opened of all the indexes.

So, CDX reduces the number of filehandles needed.

I have an application with 41 DBF-files of which 39 do have a CDX-file. This means 80 filehandles per user. All the CDX-files contain 660 indexes. One of my customers have 30 users. That means 2400 filehandles opened on the server. In case I had used NTX, that would mean more than 21000 filehandles.

Regards,

Michel D.
Genk (Belgium)


_____________________________________________________________________________________________

I use : FiveWin for (x)Harbour v. 25.12 - Harbour 3.2.0 (May 2025) - xHarbour Builder (January 2020) - Bcc773

Posts: 1387
Joined: Fri May 23, 2008 01:33 PM
Is CDX better than NTX?
Posted: Sun Oct 12, 2008 03:07 PM

Thank you for informations.

How Can I migrate to CDX. Is there anything to be careful?

Is Clipper 5.2e support CDX?

Thanks,

Regards,



Hakan ONEMLI



Harbour & MSVC 2022 & FWH 23.06
Posts: 169
Joined: Mon Feb 25, 2008 02:42 AM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 07:44 AM

Is Clipper 5.2e support CDX?


if you are still using Clipper, You have to use six driver for CDX and try with Blinker.

Regards
Fafi
Posts: 1387
Joined: Fri May 23, 2008 01:33 PM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 08:01 AM

Hi Fafi,

I use Clipper 5.2e and Blinker 5.1 for my old programs. I have compiled my old programs with xHarbour and FWH using preprocessors. So I use the same source. I just want to know that can i use CDX in Clipper 5.2e. There are DBFCDX.LIB in my Clippers LIB directory. I thought I can use it.

Thanks,

Regards,



Hakan ONEMLI



Harbour & MSVC 2022 & FWH 23.06
Posts: 169
Joined: Mon Feb 25, 2008 02:42 AM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 08:39 AM

I used sixcdx.lib and machsix.lib

Regards
Fafi

Posts: 9022
Joined: Thu Oct 06, 2005 08:17 PM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 08:56 AM
Horizon wrote:Hi Fafi,

I use Clipper 5.2e and Blinker 5.1 for my old programs. I have compiled my old programs with xHarbour and FWH using preprocessors. So I use the same source. I just want to know that can i use CDX in Clipper 5.2e. There are DBFCDX.LIB in my Clippers LIB directory. I thought I can use it.

Thanks,


Clipper 5.2e DBFCDX was very buggy. I used Comix at the time.

EMG
Posts: 169
Joined: Mon Feb 25, 2008 02:42 AM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 09:14 AM

Hi Enrico !

Can I get it ?

Regards
Fafi

Posts: 9022
Joined: Thu Oct 06, 2005 08:17 PM
Is CDX better than NTX?
Posted: Mon Oct 13, 2008 09:19 AM
fafi wrote:Hi Enrico !

Can I get it ?

Regards
Fafi


I don't know. Comix was a commercial RDD and I would be very surprised if they were still selling it.

EMG
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Comix
Posted: Mon Oct 13, 2008 09:34 AM

Hello Enrico,

as far as i know, the comix-rdd has been included
in the last Clipper-version 5.3b ( no extra product ).

Regards
Uwe :lol:

Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 9022
Joined: Thu Oct 06, 2005 08:17 PM
Re: Comix
Posted: Mon Oct 13, 2008 09:36 AM
ukoenig wrote:Hello Enrico,

as far as i know, the comix-rdd has been included
in the last Clipper-version 5.3b ( no extra product ).

Regards
Uwe :-)


Yes, but I don't know if it can be used with Clipper 5.2e.

EMG
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Comix
Posted: Mon Oct 13, 2008 09:44 AM

Hello, Enrico
The Link :

http://www.grafxsoft.com/2comix.htm

Regards
Uwe :lol:

Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 9022
Joined: Thu Oct 06, 2005 08:17 PM
Re: Comix
Posted: Mon Oct 13, 2008 09:47 AM
ukoenig wrote:Hello, Enrico
The Link :

http://www.grafxsoft.com/2comix.htm

Regards
Uwe :-)


Great! I had completely forgotten GrafX Software.

EMG

Continue the discussion