Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Obtain info about index FOR() use 1

Status
Not open for further replies.

Prospector

Programmer
Feb 25, 2002
5
US
Members:

This explantion may be a bit fuzzy, and you should feel free to add erudite clarification.

I want to retrieve in a "usable" format all the info about any index including any use of the FOR()statement.

I am working with an inherited, existing system which has no documentation. It appears as though the indices were originally constructed with the FOR(), but I do not know how to verify that.

What do you think?

Prospector
 
Well, I've always used DISPLAY STATUS to verify index tags, but here is a quick little routine you can use also:

FOR zzz = 1 TO tagcount()
?'Tag: ' + TAG(zzz)
??' Key: ' + KEY(zzz)
??IIF(DESCENDING(zzz), ' Descending', '')
??IIF (!EMPTY(FOR(zzz)), ' Expression: ' + FOR(zzz), '')
NEXT

?CDX(1) gives the name of the index file used in work area 1.

There are probably other functions you can utilize also, but these are the most common.

Dave S.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top