30.4 SDO_SAM.BIN_LAYER

Format

SDO_SAM.BIN_LAYER(
     tablename       IN VARCHAR2, 
     colname         IN VARCHAR2, 
     bin_tablename   IN VARCHAR2, 
     bin_colname     IN VARCHAR2, 
     bin_id_colname  IN VARCHAR2, 
     commit_interval IN NUMBER DEFAULT 20);

Description

Assigns each location (and the corresponding row) in a data mining table to a spatial bin.

Parameters

tablename

Name of the data mining table.

colname

Name of the column in table_name that holds the location coordinates.

bin_tablename

Name of the table that contains information (precomputed for the entire two-dimensional space) about the spatial bins.

bin_colname

Column in bin_tablename that holds the geometries for the bins.

bin_id_colname

Name of the column in the data mining table that holds the bin ID value of each geometry added to a bin. (Each affected row in the data mining table is updated with the ID value of the bin geometry in bin_tablename.)

commit_interval

Number of bin insert operations to perform before Spatial performs an internal commit operation. If commit_interval is not specified, a commit is performed after every 20 insert operations.

Usage Notes

This procedure computes the most-intersecting tile for each geometry in a specified layer using the bins in bin_tablename. The bin ID value for each geometry is added in bin_id_colname.

Using this procedure achieves the same result as using the SDO_SAM.BIN_GEOMETRY function on each row in the data mining table, using the specified bin_tablename.

Examples

The following example assigns each GEOMETRY column location and corresponding row in the POLY_4PT_TEMP data mining table to a spatial bin, and performs an internal commit operation after each bin table insertion.

CALL SDO_SAM.BIN_LAYER('POLY_4PT_TEMP', 'GEOMETRY', 'BINTBL', 'GEOMETRY', 'BIN_ID', 1);