* @param catalogType
* @return TypeId that represents the base type, null if not applicable.
*/
public static TypeId getTypeId(TypeDescriptor catalogType)
{
TypeDescriptorImpl tdi = (TypeDescriptorImpl) catalogType;
final int jdbcType = catalogType.getJDBCTypeId();
TypeId typeId = TypeId.getBuiltInTypeId(jdbcType);
if (typeId != null)
return typeId;
if (jdbcType == Types.JAVA_OBJECT) {
return new TypeId( StoredFormatIds.USERDEFINED_TYPE_ID_V3, tdi.getTypeId() );
}
if ( tdi.isRowMultiSet() )
{
return new TypeId( StoredFormatIds.ROW_MULTISET_TYPE_ID_IMPL, tdi.getTypeId() );
}
return null;
}