Page 1 of 1

Is CDX better than NTX?

Posted: Sat Oct 11, 2008 12:15 pm
by Horizon
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,

NTX or CDX

Posted: Sat Oct 11, 2008 1:35 pm
by ukoenig
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:

Posted: Sat Oct 11, 2008 6:07 pm
by Antonio Linares
Hakan,

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

Yes, XBrowse fully supports CDXs indexes.

Posted: Sat Oct 11, 2008 8:29 pm
by driessen
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.

Posted: Sun Oct 12, 2008 3:07 pm
by Horizon
Thank you for informations.

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

Is Clipper 5.2e support CDX?

Thanks,

Posted: Mon Oct 13, 2008 7:44 am
by fafi
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

Posted: Mon Oct 13, 2008 8:01 am
by Horizon
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,

Posted: Mon Oct 13, 2008 8:39 am
by fafi
I used sixcdx.lib and machsix.lib

Regards
Fafi

Posted: Mon Oct 13, 2008 8:56 am
by Enrico Maria Giordano
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

Posted: Mon Oct 13, 2008 9:14 am
by fafi
Hi Enrico !

Can I get it ?

Regards
Fafi

Posted: Mon Oct 13, 2008 9:19 am
by Enrico Maria Giordano
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

Comix

Posted: Mon Oct 13, 2008 9:34 am
by ukoenig
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:

Re: Comix

Posted: Mon Oct 13, 2008 9:36 am
by Enrico Maria Giordano
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 :lol:


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

EMG

Comix

Posted: Mon Oct 13, 2008 9:44 am
by ukoenig
Hello, Enrico
The Link :

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

Regards
Uwe :lol:

Re: Comix

Posted: Mon Oct 13, 2008 9:47 am
by Enrico Maria Giordano
ukoenig wrote:Hello, Enrico
The Link :

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

Regards
Uwe :lol:


Great! I had completely forgotten GrafX Software.

EMG