A.13.10 OPG_APIS.COUNT_TRIANGLE_PREP
Format
OPG_APIS.COUNT_TRIANGLE_PREP( edge_tab_name IN VARCHAR2, wt_undBM IN OUT VARCHAR2, wt_rnmap IN OUT VARCHAR2, wt_undAM IN OUT VARCHAR2, options IN VARCHAR2 DEFAULT NULL);
Description
Prepares for running triangle counting.
Parameters
- edge_tab_name
- 
                        Name of the property graph edge table. 
- wt_undBM
- 
                        A working table holding an undirected version of the original graph (before renumbering optimization). 
- wt_rnmap
- 
                        A working table that is a mapping table for renumbering optimization. 
- wt_undAM
- 
                        A working table holding the undirected version of the graph data after applying the renumbering optimization. 
- options
- 
                        Additional settings for operation. An optional string with one or more (comma-separated) of the following values: - 
                              CREATE_UNDIRECTED=T
- 
                              REUSE_UNDIRECTED_TAB=T
 
- 
                              
Usage Notes
The property graph edge table must exist in the database.
Examples
The following example prepares for triangle counting in a property graph named connections.
                  
set serveroutput on
DECLARE
  wt1 varchar2(100);  -- intermediate working table
  wt2 varchar2(100);
  wt3 varchar2(100);
  n number;
BEGIN
  opg_apis.count_triangle_prep('connectionsGE$', wt1, wt2, wt3);
  n := opg_apis.count_triangle_renum(
     'connectionsGE$',
      wt1,
      wt2,
      wt3,
      num_sub_ptns=>1,
      dop=>2,
      tbs => 'MYPG_TS',
      options=>'CREATE_UNDIRECTED=T,REUSE_UNDIREC_TAB=T'
      ); 
  dbms_output.put_line('total number of triangles ' || n);
END;
/
Parent topic: OPG_APIS Package Subprograms