nonJdbcAttribute.setExternalType("nonJdbcAttribute");
entity.addAttribute(nonJdbcAttribute);
return nonJdbcAttribute;
}
JDBCAdaptor adaptor = (JDBCAdaptor)_table.database().adaptor();
ERXSQLHelper sqlHelper = ERXSQLHelper.newSQLHelper(adaptor);
String externalType = sqlHelper.externalTypeForJDBCType(adaptor, _jdbcType);
if (externalType == null) {
externalType = "IF_YOU_ARE_SEEING_THIS_SOMETHING_WENT_WRONG_WITH_EXTERNAL_TYPES";
}
EOAttribute attribute = adaptor.createAttribute(_name, _name, _jdbcType, externalType, _precision, _scale, _allowsNull ? 1 : 0);
if (_width > 0) {
attribute.setWidth(_width);
}
if (_defaultValue != null) {
NSDictionary userInfo = attribute.userInfo();
NSMutableDictionary mutableUserInfo;
if (userInfo == null) {
mutableUserInfo = new NSMutableDictionary();
}
else {
mutableUserInfo = userInfo.mutableClone();
}
mutableUserInfo.setObjectForKey(_defaultValue, "default");
attribute.setUserInfo(mutableUserInfo);
}
if (_overrideValueType != null) {
if (ERXMigrationColumn.NULL_VALUE_TYPE.equals(_overrideValueType)) {
attribute.setValueType(null);
}
else {
attribute.setValueType(_overrideValueType);
}
if (sqlHelper.reassignExternalTypeForValueTypeOverride(attribute)) {
adaptor.assignExternalTypeForAttribute(attribute);
}
}
if (_overrideExternalType != null) {
attribute.setExternalType(_overrideExternalType);