AdvancedSearchRecords method: Session class

Syntax

AdvancedSearchRecords(RecordName, RecordNameOp, Descr, DescrOp, FieldName, FieldNameOp, TreeName, TreeNameOp, CaseSensitive)

Description

Use the AdvancedSearchRecords method to do more complex searches for records.

Security applies to the results of this list, that is, you have access to all the records your user ID (permission list) allows you to access.

Parameters

Parameter Description

RecordName

Specify the name of the record you want returned, as a string. Use this parameter with the RecordNameOp parameter.

RecordNameOp

Specify the operator to be used with the RecordName parameter. The valid values for this parameter are found in the Using Search Operators section, above.

Descr

Specify the description you want returned, as a string. Use this parameter with the DescrOp parameter.

DescrOp

Specify the operator to be used with the Descr parameter. The valid values for this parameter are found in the Using Search Operators section, above.

FolderName

Specify the name of the folder of the records you want returned, as a string. Use this parameter with the FolderNameOp parameter.

FolderNameOp

Specify the operator to be used with the FolderName parameter. The valid values for this parameter are found in the Using Search Operators section, above.

FieldName

Specify the name of the field associated with the record you want returned, as a string. Use this parameter with the FieldNameOp parameter.

FieldNameOp

Specify the operator to be used with the FieldName parameter. The valid values for this parameter are found in the Using Search Operators section, above.

TreeName

Specify the name of the tree associated with the record you want returned, as a string. Use this parameter with the TreeNameOp parameter.

TreeNameOp

Specify the operator to be used with the TreeName parameter. The valid values for this parameter are found in the Using Search Operators section, above.

CaseSensitive

Note: This parameter has not been implemented yet.

Specify whether the search is case-sensitive. This parameter takes a Boolean value: True, the search is case-sensitive, False, it isn't.

Returns

A reference to a QueryDBRecord collection containing zero or more records.

Note:

If the result set contains more than 300 rows, only the first 300 rows are returned.

Using Search Operators

All of the parameters for this method work in pairs, with the value in the first of the paired parameters further distinguished by the search operator used in the second parameter. For example, the value specified in FieldName is paired with the value specified in FieldNameOp.

All of the search operator parameters use the following values. Note that the format of the value of the first parameter is sometimes affected by the value of the search operator parameter.

Constant Description

%Query_AdvSrchBegins

Name begins with the values specified.

%Query_AdvSrchContains

Name contains the value specified.

%Query_AdvSrchEquals

Name equals the value specified.

%Query_AdvSrchNotEquals

The name does not equal the value specified.

%Query_AdvSrchLessThan

The name is less than the value specified.

%Query_AdvSrchLessEquals

The name is less than or equal to the value specified.

%Query_AdvSrchGreaterThan

The name is greater than the value specified.

%Query_AdvSrchGreaterEquals

The name is greater than or equal to the value specified.

%Query_AdvSrchBetween

The name is between two values specified by a comma. Do not use quotation marks. For example, ACCT1,ACCT9.

%Query_AdvSrchIn

The name is in the list specified list. The values are separated with commas. Do not use quotation marks. For example, ACCT1, ACCT2, ACCT3