Try
index on substr(code2,1,7) tag xydg
HTH
Gerhard
>Sir, I have this line of code
>
>
>index on substr(alltrim(code2),1,7) tag xydg
>
>
>it displays this error message
>
>Error building for key index "c:\windows\temp\0001qlnd0098.cdx" tag "xydg"
>
>how to overcome this
Gerhard Schmidbauer
URANUS Software GmbH