Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.apache.derby.vti
Interface VTICosting  view VTICosting download VTICosting.java


public interface VTICosting

VTICosting is the interface that the query optimizer uses to cost VTIs. The methods on the interface provide the optimizer with the following information:

This class can only be used within an SQL-J statement. Using the methods in application-side Java code results in Exceptions being thrown.

IBM Corp reserves the right to change, rename, or remove this interface at any time.


Field Summary
static double defaultEstimatedCost
          A useful constant: The default estimated cost of instantiating and iterating throught a VTI.
static double defaultEstimatedRowCount
          A useful constant: the default estimated number of rows returned by a VTI.
 
Method Summary
 double getEstimatedCostPerInstantiation(VTIEnvironment vtiEnvironment)
          Get the estimated cost for a single instantiation of a VTI.
 double getEstimatedRowCount(VTIEnvironment vtiEnvironment)
          Get the estimated row count for a single scan of a VTI.
 boolean supportsMultipleInstantiations(VTIEnvironment vtiEnvironment)
          Find out if the ResultSet of the VTI can be instantiated multiple times.
 

Field Detail

defaultEstimatedRowCount

public static final double defaultEstimatedRowCount
A useful constant: the default estimated number of rows returned by a VTI.

See Also:
Constant Field Values

defaultEstimatedCost

public static final double defaultEstimatedCost
A useful constant: The default estimated cost of instantiating and iterating throught a VTI.

See Also:
Constant Field Values
Method Detail

getEstimatedRowCount

public double getEstimatedRowCount(VTIEnvironment vtiEnvironment)
                            throws java.sql.SQLException
Get the estimated row count for a single scan of a VTI.


getEstimatedCostPerInstantiation

public double getEstimatedCostPerInstantiation(VTIEnvironment vtiEnvironment)
                                        throws java.sql.SQLException
Get the estimated cost for a single instantiation of a VTI.


supportsMultipleInstantiations

public boolean supportsMultipleInstantiations(VTIEnvironment vtiEnvironment)
                                       throws java.sql.SQLException
Find out if the ResultSet of the VTI can be instantiated multiple times.