com.syncsoft.plainsql
Class PlainTableDDL

java.lang.Object
  extended by com.syncsoft.plainsql.PlainTableDDL

public class PlainTableDDL
extends java.lang.Object

Class to assist with DDL generation. Mainly, an easy way to create scratch tables and such without hard to read long concatenated strings


Constructor Summary
PlainTableDDL(PSconnection psConnection, java.lang.String tableName)
           
 
Method Summary
 void addColumn(java.lang.String columnName, java.lang.String columnDef)
           
 void addOtherDDL(java.lang.String otherDDL)
           
 java.lang.String dateType()
           
 void execDDL()
           
 void nonUniqueIndex(java.lang.String indexname, java.lang.String columns)
           
 void primaryKey(java.lang.String pkString)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PlainTableDDL

public PlainTableDDL(PSconnection psConnection,
                     java.lang.String tableName)
Method Detail

dateType

public java.lang.String dateType()

addColumn

public void addColumn(java.lang.String columnName,
                      java.lang.String columnDef)

primaryKey

public void primaryKey(java.lang.String pkString)

nonUniqueIndex

public void nonUniqueIndex(java.lang.String indexname,
                           java.lang.String columns)
                    throws java.sql.SQLException
Throws:
java.sql.SQLException

addOtherDDL

public void addOtherDDL(java.lang.String otherDDL)

execDDL

public void execDDL()
             throws java.sql.SQLException
Throws:
java.sql.SQLException