org.apache.derby.catalog
Class GetProcedureColumns

java.lang.Object
  extended byorg.apache.derby.vti.VTITemplate
      extended byorg.apache.derby.catalog.GetProcedureColumns
All Implemented Interfaces:
java.sql.ResultSet

public class GetProcedureColumns
extends VTITemplate

Use of VirtualTableInterface to provide support for DatabaseMetaData.getProcedureColumns().

This class is called from a Query constructed in java/org.apache.derby.impl.jdbc/metadata.properties:



    

The VTI will return columns 3-14, an extra column to the specification METHOD_ID is returned to distinguish between overloaded methods.

  1. PROCEDURE_CAT String => procedure catalog (may be null)
  2. PROCEDURE_SCHEM String => procedure schema (may be null)
  3. PROCEDURE_NAME String => procedure name
  4. COLUMN_NAME String => column/parameter name
  5. COLUMN_TYPE Short => kind of column/parameter:
    • procedureColumnUnknown - nobody knows
    • procedureColumnIn - IN parameter
    • procedureColumnInOut - INOUT parameter
    • procedureColumnOut - OUT parameter
    • procedureColumnReturn - procedure return value
    • procedureColumnResult - result column in ResultSet
  6. DATA_TYPE short => SQL type from java.sql.Types
  7. TYPE_NAME String => SQL type name, for a UDT type the type name is fully qualified
  8. PRECISION int => precision
  9. LENGTH int => length in bytes of data
  10. SCALE short => scale
  11. RADIX short => radix
  12. NULLABLE short => can it contain NULL?
    • procedureNoNulls - does not allow NULL values
    • procedureNullable - allows NULL values
    • procedureNullableUnknown - nullability unknown
  13. REMARKS String => comment describing parameter/column
  14. METHOD_ID Short => cloudscape extra column (overloading)
  15. PARAMETER_ID Short => cloudscape extra column (output order)


Field Summary
private static ResultColumnDescriptor[] columnInfo
           
private  boolean isProcedure
           
private static java.sql.ResultSetMetaData metadata
           
private  short method_count
           
private  short param_number
           
private  int paramCursor
           
private  RoutineAliasInfo procedure
           
private  TypeDescriptor sqlType
           
 
Fields inherited from interface java.sql.ResultSet
CLOSE_CURSORS_AT_COMMIT, CONCUR_READ_ONLY, CONCUR_UPDATABLE, FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, HOLD_CURSORS_OVER_COMMIT, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE
 
Constructor Summary
GetProcedureColumns(AliasInfo aliasInfo, java.lang.String aliasType)
           
 
Method Summary
 void close()
           
 int getInt(int column)
           
 java.sql.ResultSetMetaData getMetaData()
           
 short getShort(int column)
           
 java.lang.String getString(int column)
           
 boolean next()
           
 
Methods inherited from class org.apache.derby.vti.VTITemplate
absolute, afterLast, beforeFirst, cancelRowUpdates, clearWarnings, deleteRow, findColumn, first, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getBoolean, getByte, getByte, getBytes, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDate, getDouble, getDouble, getFetchDirection, getFetchSize, getFloat, getFloat, getInt, getLong, getLong, getObject, getObject, getObject, getObject, getRef, getRef, getRow, getShort, getStatement, getString, getTime, getTime, getTime, getTime, getTimestamp, getTimestamp, getTimestamp, getTimestamp, getType, getUnicodeStream, getUnicodeStream, getURL, getURL, getWarnings, insertRow, isAfterLast, isBeforeFirst, isFirst, isLast, last, moveToCurrentRow, moveToInsertRow, previous, refreshRow, relative, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, updateArray, updateArray, updateAsciiStream, updateAsciiStream, updateBigDecimal, updateBigDecimal, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBoolean, updateBoolean, updateByte, updateByte, updateBytes, updateBytes, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateDate, updateDate, updateDouble, updateDouble, updateFloat, updateFloat, updateInt, updateInt, updateLong, updateLong, updateNull, updateNull, updateObject, updateObject, updateObject, updateObject, updateRef, updateRef, updateRow, updateShort, updateShort, updateString, updateString, updateTime, updateTime, updateTimestamp, updateTimestamp, wasNull
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

isProcedure

private boolean isProcedure

procedure

private RoutineAliasInfo procedure

paramCursor

private int paramCursor

method_count

private short method_count

param_number

private short param_number

sqlType

private TypeDescriptor sqlType

columnInfo

private static final ResultColumnDescriptor[] columnInfo

metadata

private static final java.sql.ResultSetMetaData metadata
Constructor Detail

GetProcedureColumns

public GetProcedureColumns(AliasInfo aliasInfo,
                           java.lang.String aliasType)
                    throws java.sql.SQLException
Method Detail

getMetaData

public java.sql.ResultSetMetaData getMetaData()

next

public boolean next()
             throws java.sql.SQLException
Throws:
java.sql.SQLException

getString

public java.lang.String getString(int column)
                           throws java.sql.SQLException
Specified by:
getString in interface java.sql.ResultSet
Overrides:
getString in class VTITemplate
Throws:
java.sql.SQLException - on unexpected JDBC error
See Also:
ResultSet

getInt

public int getInt(int column)
           throws java.sql.SQLException
Specified by:
getInt in interface java.sql.ResultSet
Overrides:
getInt in class VTITemplate
Throws:
java.sql.SQLException - on unexpected JDBC error
See Also:
ResultSet

getShort

public short getShort(int column)
               throws java.sql.SQLException
Specified by:
getShort in interface java.sql.ResultSet
Overrides:
getShort in class VTITemplate
Throws:
java.sql.SQLException - on unexpected JDBC error
See Also:
ResultSet

close

public void close()

Built on Tue 2006-10-10 19:23:47+0200, from revision exported

Apache Derby V10.1 Engine Documentation - Copyright © 1997,2005 The Apache Software Foundation or its licensors, as applicable.