Now that you've seen what a parameterized search looks like, let's turn to full-text search. Full-text search functionality involves two different operations:
In your application, it makes good sense for the indexing to be performed automatically every time a user uploads a file. The best place to do this would be the File details pop up window in the Account Details area you've created in the previous chapter (shown in the following screenshot). When the user clicks the Save button, you could index the file right there and then.
Moving on to the search interface itself, you will need to provide the user with a place to key in the search phrase and start the search. The full-text search window can be launched from the main menu by double-clicking the Search icon in the main menu. The full-text search screen features a single text box that allows the user to specify a search phrase and a Search button to run the search.
Your full-text search engine will also need to support basic Boolean searches. Boolean searches allow you to specify how multiple words in a search phrase are used in a search. In the previous screenshot, for instance, the search phrase Medical OR Certificate will indicate that documents containing either the word Medical or the word Certificate will be returned.
In contrast, a search phrase consisting of two words Medical Certificate would indicate an AND
relationship between these words, and would only return documents that contains both words. The following is a list of basic Boolean search operators commonly found in most search engines:
Boolean operator |
Description |
---|---|
|
The Examples: "Medical AND Certificate" "Medical Certificate" |
|
The |
|
The |
The full-text search functionality runs the search phrase (with the Boolean logic applied) against the stored Keywords metadata for all documents. This can be done at the database level. All documents with matching results are returned in a paged list (again making use of the paging control you've created in the previous chapter).
The summary details window will display a summary of the text containing the search phrase (which is highlighted in bold in the previous screenshot). The name and size of the document is also displayed, with an Open file link at the side to let the user open the file directly. The name of the account is displayed as a link so that end users can easily jump into the details window of the account if they wish to.
3.146.152.99