RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TADOTable.IndexFieldNames Property

Lists the columns to use for a persistent sort of the recordset.

Pascal
property IndexFieldNames: string;
C++
__property AnsiString IndexFieldNames;

Use IndexFieldNames as an alternative method of specifying the sort order of a recordset. IndexFieldNames is a direct implementation of the Sort property of the ADO recordset object, with the field list from IndexFieldNames being used for the Sort property. The actual sorting of data occurs on the OLE DB side and use of indexes for the sort depend on the particular provider. 

To use IndexFieldNames to establish a recordset's sort order, the recordset must have been opened using a client-side cursor (the dataset component's CursorLocation property must be clUseClient). An exception is raised on attempts to use IndexFieldNames with server-side cursors. 

IndexFieldNames may be used to set the sort order for the detail table in a master-detail link, increasing the performance of the link. However, use of IndexFieldNames is not required for master-detail links. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!