uk.org.ogsadai.client.dbcreate
Class CreateTestDB2DB
java.lang.Object
|
+--uk.org.ogsadai.client.dbcreate.CreateTestDB
|
+--uk.org.ogsadai.client.dbcreate.CreateTestDB2DB
- public class CreateTestDB2DB
- extends CreateTestDB
This program will populate a table in a DB2 database
called littleblackbook and populate it with 10,000 address entries
consisting of a name (First, Surname). Address and telephone number.
The numberOfEntries field may be modified to generate a table
with any desired number of rows. The nth row in each possible
database will be identical across each one which has at least
n rows (assuming Random is implemented the same on all Java jdks).
Usage:
java uk.org.ogsadai.client.dbcreate.CreateTestDB2DB [-driverclass DB2DriverClass]
[-host DB2HostName] [-port DB2PortNumber] [-database DB2DatabaseName]
[-username DB2UserName] [-password DB2Password]
[-tablename NameOfTableToCreate] [-rows NumberOfRowsToCreate]
Default Settings:
DB2DriverClass: com.ibm.db2.jcc.DB2Driver
DB2HostName: localhost
DB2PortNumber: 50000
DB2DatabaseName: ogsadai
DB2UserName: ogsadai
DB2Password: ogsadai
NameOfTableToCreate: littleblackbook
NumberOfRowsToCreate: 10000
- Author:
- The OGSA-DAI Project Team
Constructor Summary |
CreateTestDB2DB(java.lang.String[] args)
Creates and populates a DB2 test database table according to the
specified settings or the default settings if no arguments are used. |
Method Summary |
static void |
main(java.lang.String[] args)
|
protected void |
populateDatabase()
Populates the test database with the test data. |
protected void |
setDefaultSettings()
Sets the default settings for the client. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
COPYRIGHT_NOTICE
private static final java.lang.String COPYRIGHT_NOTICE
- See Also:
- Constant Field Values
CreateTestDB2DB
public CreateTestDB2DB(java.lang.String[] args)
- Creates and populates a DB2 test database table according to the
specified settings or the default settings if no arguments are used.
- Parameters:
args
- arguments passed to the main method.
main
public static void main(java.lang.String[] args)
setDefaultSettings
protected void setDefaultSettings()
- Description copied from class:
CreateTestDB
- Sets the default settings for the client.
- Specified by:
setDefaultSettings
in class CreateTestDB
populateDatabase
protected void populateDatabase()
throws CreateTestDatabaseException
- Description copied from class:
CreateTestDB
- Populates the test database with the test data.
- Specified by:
populateDatabase
in class CreateTestDB
CreateTestDatabaseException