Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (Français) » SQL Anywhere Server - SQL Reference » System Objects » System procedures » Alphabetical list of system procedures

 

sa_text_index_vocab system procedure

Lists all terms that appear in a text index, and the total number of indexed values that each term appears in.

Syntax
sa_text_index_vocab(
'text-index-name',
'table-name',
'table-owner'
)
Arguments
  • text-index-name   Use this CHAR(128) parameter to specify the name of the text index.

  • table-name   Use this CHAR(128) parameter to specify the name of the table on which the text index is built.

  • table-owner   Use this CHAR(128) parameter to specify the owner of the table.

Result set
Column name Data type Description
term VARCHAR(60) A term in the text index.
freq BIGINT The number of indexed values the term appears in.
Remarks

The sa_text_index_vocab system procedure returns all terms that appear in a text index, and the total number of indexed values that each term appears in (which is less than the total number of occurrences if the term appears multiple times in some indexed values).

The sa_text_index_vocab system procedure has the following limitations:

  • It cannot be used with a CALL statement.

  • It cannot be used in a statement within a procedure.

  • Parameter values cannot be host variables or expressions. The arguments text-index-name, table-name, and table-owner must be constraints or variables.

Permissions

DBA authority, or SELECT permission on the indexed table is required.

Side effects

None

See also
Example

The following example builds a text index called VocabTxtIdx on the Products.Description column in the sample database. The next statement executes the sa_text_index_vocab system procedure to return all the terms that appear in the text index.

CREATE TEXT INDEX VocabTxtIdx2 ON Products( Description );
SELECT * 
   FROM sa_text_index_vocab( 'VocabTxtIdx2', 'Products', 'GROUPO' );
term freq
Cap 2
Cloth 1
Cotton 2
Crew 1
Hooded 1
neck 2
... ...