Esempio n. 1
0
 // Shameless stolen from PostresqlSynchronizationFactory - davidleber
 //
 // I blame statementstToConvertColumnType for not taking a damn EOAttribute for
 // having to steal this from EOSQLExpression
 public String columnTypeStringForAttribute(EOAttribute attribute) {
   if (attribute.precision() != 0) {
     String precision = String.valueOf(attribute.precision());
     String scale = String.valueOf(attribute.scale());
     return _NSStringUtilities.concat(attribute.externalType(), "(", precision, ",", scale, ")");
   }
   if (attribute.width() != 0) {
     String width = String.valueOf(attribute.width());
     return _NSStringUtilities.concat(attribute.externalType(), "(", width, ")");
   }
   return attribute.externalType();
 }