Page 1 of 1

Indexing Problem

Posted: Mon May 28, 2012 2:28 am
by fransm
Hi,

Can somebody pse help me with an indexing problem.

I am trying to create a combined index with the following code:

ordCreate("Fleet","FltDepot","Upper(Depot) + Upper(FltNo)" , ;
&(cStringBlock+"Upper(Depot) + Upper(FltNo)"+"}"),.f., .T. )

The "Depot" field is sorted correctly but, not the "Fltno" field. I have tried to use alltrim() and change the collation settings, but this has a minimal effect and does not seem to be any logic in the sort order.

This seems to be such a straight forward operation, that I think I might be missing something. Is there an issue with indexing that I don't know about ?

Alaska 1.9 355 - Hotfixes 1 - 19 installed
Express 1.9 255
Using CdxDbe

regards

Frans

Re: Indexing Problem

Posted: Mon May 28, 2012 9:17 am
by rdonnay
What is in cStringBlock?

Re: Indexing Problem

Posted: Mon May 28, 2012 9:40 am
by RDalzell
Frans,

Try:
ordCreate("Fleet", "FltDepot", "Upper(Depot) + Upper(FltNo)", , .f., .t. )

It appears that your intended codeblock is not properly formatted (depending upon the content of cStringBlock).

Re: Indexing Problem

Posted: Mon May 28, 2012 11:11 pm
by fransm
Hi Roger, Rick

This is cStringBlock

cStringBlock := ;
"{||IIF(Recno()%nNoRecs==0,oProgress:Update( (RecNo()/RecCount()) * 100), nil),"

Rick,

I tried your code but the result is still the same

regards

Frans