提交 5be66a06 authored 作者: Evgenij Ryazanov's avatar Evgenij Ryazanov

Revert "Remove ExtTypeInfo code from ExpressionColumn.getValue()"

This reverts commit 4f476d40.
上级 fad4a812
...@@ -21,9 +21,11 @@ import org.h2.table.Column; ...@@ -21,9 +21,11 @@ import org.h2.table.Column;
import org.h2.table.ColumnResolver; import org.h2.table.ColumnResolver;
import org.h2.table.Table; import org.h2.table.Table;
import org.h2.table.TableFilter; import org.h2.table.TableFilter;
import org.h2.value.ExtTypeInfo;
import org.h2.value.TypeInfo; import org.h2.value.TypeInfo;
import org.h2.value.Value; import org.h2.value.Value;
import org.h2.value.ValueBoolean; import org.h2.value.ValueBoolean;
import org.h2.value.ValueNull;
/** /**
* A expression that represents a column of a table or view. * A expression that represents a column of a table or view.
...@@ -214,6 +216,12 @@ public class ExpressionColumn extends Expression { ...@@ -214,6 +216,12 @@ public class ExpressionColumn extends Expression {
throw DbException.get(ErrorCode.MUST_GROUP_BY_COLUMN_1, getSQL()); throw DbException.get(ErrorCode.MUST_GROUP_BY_COLUMN_1, getSQL());
} }
} }
if (value != ValueNull.INSTANCE) {
ExtTypeInfo extTypeInfo = column.getType().getExtTypeInfo();
if (extTypeInfo != null) {
return extTypeInfo.cast(value);
}
}
return value; return value;
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论