1 64 65 package com.jcorporate.expresso.core.dbobj.tests; 66 67 import com.jcorporate.expresso.core.db.DBConnection; 68 import com.jcorporate.expresso.core.db.DBException; 69 import com.jcorporate.expresso.core.dbobj.DBObject; 70 71 72 77 public class Test1 78 extends DBObject { 79 83 public Test1() 84 throws DBException { 85 super(); 86 } 87 88 95 public Test1(DBConnection oneConnection) throws DBException { 96 super(oneConnection); 97 } 98 99 100 107 public void setupFields() 108 throws DBException { 109 setTargetTable("TEST1"); 110 setDescription("Test One"); 111 setCharset("ISO-8859-1"); 112 addField("TestKey", "int", 0, false, "Test Table Key"); 113 addField("BigIntTest", "bigint", 0, true, "Big Int Test"); 114 addField("BinaryTest", "binary", 0, true, "Binary Test"); 115 addField("BitTest", "bit", 0, true, "Bit Test"); 116 addField("BooleanTest", "boolean", 0, true, "Boolean Test"); 117 addField("BlobTest", "blob", 0, true, "Blob Test"); 118 addField("CharTest", "char", 30, true, "Char Test"); 119 addField("ClobTest", "clob", 0, true, "Clob Test"); 120 addField("DateTest", "date", 0, true, "Date Test"); 121 addField("DecimalTest", "decimal", 0, true, "Decimal Test"); 122 addField("DoubleTest", "double", 0, true, "Double Test"); 123 addField("FloatTest", "float", 9, 3, true, "Float Test"); 124 addField("IntTest", "int", 0, true, "Int Test"); 125 addField("NumericTest", "numeric", 0, true, "Numeric Test"); 126 addField("RealTest", "real", 9, true, "Real Test"); 127 addField("SmallIntTest", "smallint", 0, true, "Smallint Test"); 128 addField("TimeTest", "time", 0, true, "Time Test"); 129 addField("TimeStampTest", "timestamp", 0, true, "Time Stampt Test"); 130 addField("DateTimeTest", "datetime", 0, true, "Date Time Test"); 131 addField("TinyIntTest", "tinyint", 0, true, "Tiny Int Test"); 132 addField("VarCharTest", "varchar", 30, true, "Varchar Test"); 133 addField("TextTest", "text", 0, true, "Text Test"); 134 addField("AutoIncTest", "auto-inc", 0, true, "AutoIncrement Test"); 135 136 addKey("TestKey"); 148 } 149 150 151 } 152 | Popular Tags |