Yes, DTOC(,1) and TTOC(,1) functions has to be used in the index keys for compound indexes to get proper sort order.
>I had DTOC(start_dt). Found where I needed DTOC(start_dt ,1). This seems to fix the index problem. Thanks for the reply. It got me thinking.
>
>
>>>Wanted to add that the incorrect sorting is when I use the date in an index of a table. Do I have to year() + month() + day() for the index?
>>>
>
>>Can you post index key expression?
--sb--