Top Description Constructors Methods
org.apache.derby.impl.tools.dblook

public Class DB_Sequence

extends Object
Class Inheritance
Imports
java.sql.Connection, .Statement, .PreparedStatement, .ResultSet, .SQLException, .DatabaseMetaData, java.util.HashMap, org.apache.derby.tools.dblook

Dblook implementation for SEQUENCEs.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private static String

Returns:

DDL for the current stored sequence
createSequenceString
(String
Fully qualified name of the sequence
fullName
,
String
Name of the datatype of the sequence
dataTypeName
,
long
First value to use in the range of the sequence
startValue
,
long
Smallest value in the range
minimumValue
,
long
Largest value in the range
maximumValue
,
long
Step size of the sequence
increment
,
String
CYCLE or NO CYCLE
cycleOption
)

Generate DDL for a specific sequence.

public static void
doSequences(Connection
Connection to the source database.
conn
)

Generate the DDL for all sequences and output it via Logs.java.

private static String
stripNotNull(String datatypeName)

Strip the trailing NOT NULL off of the string representation of a datatype

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

DB_Sequenceback to summary
public DB_Sequence()

Method Detail

createSequenceStringback to summary
private static String createSequenceString(String fullName, String dataTypeName, long startValue, long minimumValue, long maximumValue, long increment, String cycleOption) throws SQLException

Generate DDL for a specific sequence.

Parameters
fullName:String

Fully qualified name of the sequence

dataTypeName:String

Name of the datatype of the sequence

startValue:long

First value to use in the range of the sequence

minimumValue:long

Smallest value in the range

maximumValue:long

Largest value in the range

increment:long

Step size of the sequence

cycleOption:String

CYCLE or NO CYCLE

Returns:String

DDL for the current stored sequence

doSequencesback to summary
public static void doSequences(Connection conn) throws SQLException

Generate the DDL for all sequences and output it via Logs.java.

Parameters
conn:Connection

Connection to the source database.

stripNotNullback to summary
private static String stripNotNull(String datatypeName)

Strip the trailing NOT NULL off of the string representation of a datatype