15.119 SEM_APIS.IS_TRIPLE
Format
SEM_APIS.IS_TRIPLE( model_id IN NUMBER, subject IN VARCHAR2, property IN VARCHAR2, object IN VARCHAR2) RETURN VARCHAR2;
or
SEM_APIS.IS_TRIPLE( model_name IN VARCHAR2, subject IN VARCHAR2, property IN VARCHAR2, object IN VARCHAR2) RETURN VARCHAR2;
Description
Checks if a statement is an existing triple in the specified model in the database.
Parameters
- model_id
-
ID number of the semantic technology model. Must match a value in the MODEL_ID column of the SEM_MODEL$ view, which is described in Metadata for Models.
- model_name
-
Name of the semantic technology model. Must match a value in the MODEL_NAME column of the SEM_MODEL$ view, which is described in Metadata for Models.
- subject
-
Subject. Must match a value in the VALUE_NAME column of the RDF_VALUE$ table, which is described in Statements.
- property
-
Property. Must match a value in the VALUE_NAME column of the RDF_VALUE$ table, which is described in Statements.
- object
-
Object. Must match a value in the VALUE_NAME column of the RDF_VALUE$ table, which is described in Statements.
Usage Notes
This function returns the string value FALSE
, TRUE
, or TRUE (EXACT)
:
-
FALSE
means that the statement is not a triple in the specified model the database. -
TRUE
means that the statement matches the value of a triple or is the canonical representation of the value of a triple in the specified model the database. -
TRUE (EXACT)
means that the specifiedsubject
,property
, andobject
values have exact matches in a triple in the specified model in the database.
Examples
The following example checks if a statement is a triple in the database. In this case, there is an exact match. (This example is an excerpt from Example 1-129 in Example: Journal Article Information.)
SELECT SEM_APIS.IS_TRIPLE( 'articles', 'http://nature.example.com/Article2', 'http://purl.org/dc/terms/references', 'http://nature.example.com/Article3') AS is_triple FROM DUAL; IS_TRIPLE -------------------------------------------------------------------------------- TRUE (EXACT)
Parent topic: SEM_APIS Package Subprograms