284
<cfindex action="update"
<!--- Search the collection --->
<!--- Use the wildcard * to contain the search string --->
<cfsearch collection="ldap_query"
<!--- Output returned records --->
<cfoutput query="s_ldap">
</cfoutput>
Indexing cfpop query results
The contents of mail servers are generally quite volatile; specifically, the message
number is reset as messages are added and deleted. To avoid mismatches between
the unique message number identifiers on the server and in the Verity collection,
you should re-index the collection before processing a search.
As with the other query types, you need to provide a unique value for the
attribute and enter the data fields to index in the
The following example updates the pop_query collection with the current mail for
user1 and searches and returns the message number and subject line for all
messages containing the word "action":
<!--- Run POP query --->
<cfpop action="getall"
<!--- Output POP query result set --->
<cfoutput query="p_messages">
<hr>
</cfoutput>
<!--- Index result set --->
<cfindex action="update"
collection="ldap_query"
key="dn"
type="custom"
title="o"
query="OrgList"
body="telephonenumber">
name="s_ldap"
criteria="*617*">
#Key#, #Title#, #Body# <br>
name="p_messages"
server="mail.company.com"
userName="user1"
password="user1">
#messagenumber# <br>
#from# <br>
#to# <br>
#subject# <br>
#body# <br>
collection="pop_query"
key="messagenumber"
Chapter 15 Indexing and Searching Data
attribute.
body
key
Need help?
Do you have a question about the COLDFUSION 5-DEVELOPING and is the answer not in the manual?