Oracle8i interMedia Text Reference
Release 2 (8.1.6)

Part Number A77063-01

Library

Product

Contents

Index

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

CTX_DDL Package, 12 of 24


CREATE_SECTION_GROUP

Creates a section group for defining sections in a text column.

When you create a section group, you can add to it zone, field, or special sections with ADD_ZONE_SECTION, ADD_FIELD_SECTION, or ADD_SPECIAL_SECTION.

When you index, you name the section group in the parameter string of CREATE INDEX or ALTER INDEX.

After indexing, you can query within your defined sections with the WITHIN operator.

Syntax

CTX_DDL.CREATE_SECTION_GROUP(
  group_name     in    varchar2,
  group_type     in    varchar2
);
group_name

Specify the section group name to create as [user.]section_group_name. This parameter must be unique within an owner.

group_type

Specify section group type. The group_type parameter can be one of:

Section Group Preference  Description 

NULL_SECTION_GROUP 

This is the default. Use this group type when you define no sections or when you define only SENTENCE or PARAGRAPH sections. 

BASIC_SECTION_GROUP 

Use this group type for defining sections where the start and end tags are of the form <A> and </A>

HTML_SECTION_GROUP 

Use this group type for defining sections in HTML documents. 

XML_SECTION_GROUP 

Use this group type for defining sections in XML-style tagged documents. 

AUTO_SECTION_GROUP 

Use this group type to automatically create a zone section for each start-tag/end-tag pair in an XML document. The section names derived from XML tags are case-sensitive as in XML.

Attribute sections are created automatically for XML tags that have attributes. Attribute sections are named in the form attribute@tag.

Empty tags, processing instructions, and comments are not indexed.

The following limitations apply to automatic section groups:

  • You cannot add zone, field or special sections to an automatic section group.

  • Automatic sectioning does not index XML document types (root elements.)

  • The length of the indexed tags including prefix and namespace cannot exceed 64 characters. Tags longer than this are not indexed.

 

NEWS_SECTION_GROUP 

Use this group for defining sections in newsgroup formatted documents according to RFC 1036. 

Example

The following command creates a section group called htmgroup with the HTML group type.

begin
ctx_ddl_create_section_group('htmgroup', 'HTML_SECTION_GROUP');
end;

The following command creates a section group called auto with the AUTO_SECTION_GROUP group type to be used to automatically index tags in XML documents.

begin
ctx_ddl_create_section_group('auto', 'AUTO_SECTION_GROUP');
end;

Related Topics

WITHIN operator in Chapter 4.

"Section Group Types" in Chapter 3.

ADD_ZONE_SECTION

ADD_FIELD_SECTION

ADD_SPECIAL_SECTION

REMOVE_SECTION

DROP_SECTION_GROUP


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