Ejemplo n.º 1
0
 @Override
 protected void addIndexField(StringBuilder builder, IDBField field) {
   super.addIndexField(builder, field);
   if (field.getType() == DBType.VARCHAR) {
     builder.append("("); // $NON-NLS-1$
     builder.append(field.getPrecision());
     builder.append(")"); // $NON-NLS-1$
   }
 }
Ejemplo n.º 2
0
  @Override
  protected String getTypeName(IDBField field) {
    DBType type = field.getType();
    switch (type) {
      case VARCHAR:
      case CLOB:
        return "LONGTEXT"; //$NON-NLS-1$
      case BLOB:
        return "LONGBLOB"; //$NON-NLS-1$
    }

    return super.getTypeName(field);
  }
Ejemplo n.º 3
0
  @Override
  protected String getTypeName(IDBField field) {
    DBType type = field.getType();
    switch (type) {
      case BIT:
        return "SMALLINT"; //$NON-NLS-1$

      case FLOAT:
        return "REAL"; //$NON-NLS-1$

      case LONGVARCHAR:
        return "VARCHAR"; //$NON-NLS-1$

      case NUMERIC:
        return "DECIMAL"; //$NON-NLS-1$

      case LONGVARBINARY:
      case VARBINARY:
        return "BLOB"; //$NON-NLS-1$
    }

    return super.getTypeName(field);
  }