MACROMEDIA COLDFUSION 4.5-DEVELOPING WEB Develop Manual page 202

Developing web applications with coldfusion
Table of Contents

Advertisement

176
YearPlaceText (Continued)
Year
1991
1992
The following application page matches records that have 1990 in the TEXT column
and are in the Place Utah. The search is performed against the collection that contains
the TEXT column and then is narrowed further by searching the string "Utah" in the
CF_TITLE document field. Recall that document fields are defaults defined in every
collection corresponding to the values you define for URL, TITLE, and KEY in the
CFINDEX tag.
<CFQUERY NAME="GetText"
DATASOURCE="TEST1">
SELECT Year+Place
</CFQUERY>
<CFINDEX COLLECTION="testcollection"
ACTION="Update"
TYPE="Custom"
TITLE="Identifier"
KEY="Identifier"
BODY="TEXT"
QUERY="GetText">
<CFSEARCH NAME="GetText_Search"
COLLECTION="testcollection"
TYPE="Explicit"
CRITERIA="1990 and CF_TITLE <SUBSTRING> Utah">
<CFOUTPUT>
Record Counts: <BR>
#GetText.RecordCount# <BR>
#GetText_Search.RecordCount# <BR>
</CFOUTPUT>
<CFOUTPUT>
Query Results --- Should be 5 rows <BR>
</CFOUTPUT>
<CFOUTPUT QUERY="Gettext">
#Identifier# <BR>
</CFOUTPUT>
<CFOUTPUT>
Search Results -- should be 1 row <BR>
Place
Text
Oregon
Text about Oregon 1991
Utah
Text about Utah 1992
AS Identifier, text
FROM YearPlaceText
Developing Web Applications with ColdFusion

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the COLDFUSION 4.5-DEVELOPING WEB and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Coldfusion 4.5

Table of Contents