Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.

ID: 13327, Using Indexes to find Items in Databases

by Frank Hirka Email: Anonymous

Download Details
FTP  download also available 0 bytes
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For Delphi, Version 1.0  to 4.0 19 downloads
Copyright: No significant restrictions

Size: 0 bytes
Updated on Mon, 17 May 1999 00:00:00 GMT
Originally uploaded on Mon, 17 May 1999 00:00:00 GMT
This Procedure is the same as TTable.GotoNearest used with indexed Tables but is simpler to use.
e.g. GoNear(fTableName, [b, b, b, ...], [c, c, c, ...];
NOTE: if string is NOT found Moves to next record}

fTableName : TableName
fFieldNames : Set of FieldNames
fIndexStrings : Set of strings
the SET of (one or more indexed) FieldNames and SET of one or more search strings must be in square brackets and the items comma delimited

Procedure GoNear(fTableName: TDataSet; fFieldNames, fIndexStrings: Array of string);
I : Integer;
with TTable(fTableName) do
for I := 0 to High(fFieldNames) do
FieldByName(fFieldNames[I]).asstring := fIndexStrings[I];
end; {with}

   Latest Comments  View All Add New

Move mouse over comment to see the full text

Could not retrieve comments. Please try again later.

Server Response from: ETNACDC04