Creating a search tool for ColdFusion applications
513
Note:
You can map a collection currently available on your network or local disk by creating a local
reference (an alias) for that collection. In this procedure, enter the collection alias as the collection
name, and enter a UNC (Universal Naming Convention) path to the folder for the collection.
You have successfully created a collection, DemoDocs, that currently has no data. A collection
becomes populated with data when you index it. For more information, see the next section,
“About indexing a collection” on page 513
.
About indexing a collection
A new collection is an empty shell that must be indexed before you search it. The indexing
procedure also populates the collection with data contained in the collection’s files. Similar to
creating a collection, you can index a collection either in the ColdFusion MX Administrator or
programmatically.
Note:
You can index and search against collections created outside of ColdFusion by using the
external
attribute of
cfindex
and
cfsearch
.
Use the following guidelines to determine which method to use:
The
cfcollection
tag has the following
action
attribute values that can fix or improve your
index:
•
repair
Repairs the internal index files of a collection. This might take a few minutes for large
collections.
•
optimize
Optimizes a collection. Use this if you notice that your searches on a collection
take longer than previously.
Updating an index
Documents are modified frequently in many user environments. After you index your
documents, any changes that you make are not reflected in subsequent Verity searches until you
reindex the collection. Depending on your environment, you can create a scheduled task to
automatically keep your indexes current. For more information on scheduled tasks, see
Configuring and Administering ColdFusion MX
.
Use the Administrator
Use the cfindex tag
To index document files
To index ColdFusion query results
When the collection does not require
frequent updates
When the collection requires frequent updates
To create the collection without writing any
CFML code
To dynamically update a collection from a ColdFusion
application page
To create a collection once
When the collection requires updating by others
Summary of Contents for COLDFUSION MX 61-DEVELOPING COLDFUSION MX
Page 1: ...Developing ColdFusion MX Applications...
Page 22: ...22 Contents...
Page 38: ......
Page 52: ...52 Chapter 2 Elements of CFML...
Page 162: ......
Page 218: ...218 Chapter 10 Writing and Calling User Defined Functions...
Page 250: ...250 Chapter 11 Building and Using ColdFusion Components...
Page 264: ...264 Chapter 12 Building Custom CFXAPI Tags...
Page 266: ......
Page 314: ...314 Chapter 14 Handling Errors...
Page 344: ...344 Chapter 15 Using Persistent Data and Locking...
Page 349: ...About user security 349...
Page 357: ...Security scenarios 357...
Page 370: ...370 Chapter 16 Securing Applications...
Page 388: ...388 Chapter 17 Developing Globalized Applications...
Page 408: ...408 Chapter 18 Debugging and Troubleshooting Applications...
Page 410: ......
Page 426: ...426 Chapter 19 Introduction to Databases and SQL...
Page 476: ...476 Chapter 22 Using Query of Queries...
Page 534: ...534 Chapter 24 Building a Search Interface...
Page 556: ...556 Chapter 25 Using Verity Search Expressions...
Page 558: ......
Page 582: ...582 Chapter 26 Retrieving and Formatting Data...
Page 668: ......
Page 734: ...734 Chapter 32 Using Web Services...
Page 760: ...760 Chapter 33 Integrating J2EE and Java Elements in CFML Applications...
Page 786: ...786 Chapter 34 Integrating COM and CORBA Objects in CFML Applications...
Page 788: ......