Oracle Text Reference Release 9.0.1 Part Number A90121-01 |
|
CTX_THES Package , 22 of 30
This function returns the preferred term of a phrase as recorded in the specified thesaurus.
CTX_THES.PT(restab IN OUT NOCOPY EXP_TAB, phrase IN VARCHAR2, tname IN VARCHAR2 DEFAULT 'DEFAULT') RETURN varchar2;
CTX_THES.PT(phrase IN VARCHAR2, tname IN VARCHAR2 DEFAULT 'DEFAULT') RETURN varchar2;
Optionally, specify the name of the expansion table to store the results. This table must be of type EXP_TAB which the system defines as follows:
type exp_rec is record ( xrel varchar2(12), xlevel number, xphrase varchar2(256) ); type exp_tab is table of exp_rec index by binary_integer;
See Also:
"CTX_THES Result Tables and Data Types" in Appendix A, "Result Tables" for more information about EXP_TAB. |
Specify phrase to lookup in thesaurus.
Specify thesaurus name. If not specified, system default thesaurus is used.
This function returns the preferred term as a string in the form:
{pt}
Consider a thesaurus MY_THES with the following preferred term definition for automobile:
AUTOMOBILE PT CAR
To look up the preferred term for automobile, execute the following code:
declare terms varchar2(2000); begin terms := ctx_thes.pt('AUTOMOBILE','MY_THES'); dbms_output.put_line('The prefered term for automobile is: '||terms); end;
Preferred Term (PT) Operator in Chapter 3, "CONTAINS Query Operators"
|
Copyright © 1996-2001, Oracle Corporation. All Rights Reserved. |
|