Contact Template
get()
Searches for individuals, OUs, or communities in the contacts database.
Syntax
dataIterator = rb.contact.get(keywords, flags)
Parameters
The 'get' method takes 2 parameters:
Name | Type/Value | Range/Length | Description | keywords | array of strings | array of 0-10 keyword strings, of < 128 characters each | Required. A list of up to 10 keywords to be searched for. Keywords are additive (that is to say that searches will match any entry which contains any of the keywords | flags | struct searchFlags | see definition | Required. Flags, see definition of searchflags |
Results
The 'get' method returns an iterator of structure:
Remarks
The keywords array holds a list of all keywords to be searched for. Wildcards of % (representing any length of unspecified characters) and _ (representing a single unspecified character) can be used in the search. These characters may be introduced by the integration partners implicitly or typed in by the user. This will mean however that these characters may not themselves be searched for. Only alphabetical characters and numbers may be used in a search.
Example The following example gets all Individual entities which contain "Fred", or "Joe" in their name field, printing out the names
var flags = {searchIndividual:1, searchOU:0, searchCommunity:0, searchName:1};
var keywords = ["Fred", "Joe"]
var results = rb.contact.get(keywords, flags);
while(results.getNextRow())
rb.page.write("Search matched " + results.name +"<BR>");
|