Oracle8i interMedia Text Migration
Release 2 (8.1.6)

Part Number A77061-01

Library

Product

Contents

Index

Go to previous page Go to beginning of chapter Go to next page

Document Presentation, 2 of 3


Highlighting

In interMedia Text query applications, you can present selected documents with query terms highlighted for text queries or with themes highlighted for ABOUT queries.

You can generate three types of output associated with highlighting: a marked-up version of the document, a plain text version of the document (filtered output), and highlight offset information for the document.

In pre-8.1, you used the procedure CTX_QUERY.CTX_HIGHLIGHT the three types of output listed above, namely a marked-up version of the document, a plain text version of the document (filtered output), and highlight offset information for the document.

In interMedia Text 8.1, these three types of output are generated by three different procedures in the CTX_DOC (document services) package. In addition, you can get plain text and HTML versions for each type of output.

The result tables you use to store this output in 8.1 are also different from pre-8.1 result tables.

In interMedia Text 8.1, the output for theme highlighting is different from what is was in pre-8.1. In pre-8.1, the system highlighted paragraphs in the document that best represented the query. In interMedia Text 8.1, individual themes, which can be words or phrases, are highlighted.

Pre-8.1 Method

Use CTX_QUERY.HIGHLIGHT to obtain highlight information, marked-up documents, and filtered documents.

For example, to highlight all the occurrences of the term dog in a document identified by textkey 14, issue the following statement:

ctx_query.highlight (
       cspec=> 'text_policy',
       textkey => '14', 
       query => 'dog', 
       id=> 14, 
       hightab => 'highlight_ascii', 
       mutab   => 'mu_ascii' );

This example stores the offset information in the HIGHTAB table and the highlighted marked-up document in the MU_ASCII table.

New 8.1 Solutions

Text highlighting

For text highlighting, the behavior is same as in pre-8.1. You supply the query, and Oracle highlights words in document that satisfy the query. You can obtain plain-text or HTML highlighting.

Theme Highlighting

For theme queries, interMedia Text 8.1 procedures highlight and markup words or phrases that best represent the theme query. This is behavior is different from pre-8.1 where paragraphs are highlighted for theme queries.

Highlight Procedure

Highlight offset information is useful for when you write your own custom routines for displaying documents.

To obtain highlight offset information, use the CTX_DOC.HIGHLIGHT procedure. This procedure takes a query and a document, and returns highlight offset information for either plaintext or HTML formats.

With offset information, you can render a highlighted version of document as desired. For example, you can display the document with different font types or colors rather than using the standard plain text markup obtained from CTX_DOC.MARKUP.

See Also:

For more information about using CTX_DOC.HIGHLIGHT, see its specification in the Oracle8i interMedia Text Reference.  

Markup Procedure

The CTX_DOC.MARKUP procedure takes a document reference and a query, and returns a marked-up version of the document. The output can be either marked-up plaintext or marked-up HTML.

In 8.1, you can customize the markup sequence for HTML navigation.

See Also:

For more information about CTX_DOC.MARKUP, see its specification in the Oracle8i interMedia Text Reference.  

Filter Procedure

When documents are stored in their native formats such as Microsoft Word, you can use the filter procedure CTX_DOC.FILTER to obtain either a plain text or HTML version of the document.

See Also:

For more information about CTX_DOC.FILTER, see its specification in the Oracle8i interMedia Text Reference.  

8.1.6 Features

In release 8.1.6, you can use all the highlighting, filtering, and markup features of release 8.1.5.

In 8.1.6, the following additional new features apply to document services:


Go to previous page Go to beginning of chapter Go to next page
Oracle
Copyright © 1996-2000, Oracle Corporation.

All Rights Reserved.

Library

Product

Contents

Index