提交 f2b73153 authored 作者: Evgenij Ryazanov's avatar Evgenij Ryazanov

Remove Expression.getValueType()

上级 e2dea134
......@@ -2439,8 +2439,7 @@ public class Parser {
boolean canBeNumber = !readIf(EQUAL);
SelectOrderBy order = new SelectOrderBy();
Expression expr = readExpression();
if (canBeNumber && expr instanceof ValueExpression &&
expr.getValueType() == Value.INT) {
if (canBeNumber && expr instanceof ValueExpression && expr.getType().getValueType() == Value.INT) {
order.columnIndexExpr = expr;
} else if (expr instanceof Parameter) {
recompileAlways = true;
......@@ -3837,14 +3836,14 @@ public class Parser {
read();
if (currentTokenType == VALUE) {
r = ValueExpression.get(currentValue.negate());
if (r.getValueType() == Value.LONG &&
int rType = r.getType().getValueType();
if (rType == Value.LONG &&
r.getValue(session).getLong() == Integer.MIN_VALUE) {
// convert Integer.MIN_VALUE to type 'int'
// (Integer.MAX_VALUE+1 is of type 'long')
r = ValueExpression.get(ValueInt.get(Integer.MIN_VALUE));
} else if (r.getValueType() == Value.DECIMAL &&
r.getValue(session).getBigDecimal()
.compareTo(Value.MIN_LONG_DECIMAL) == 0) {
} else if (rType == Value.DECIMAL &&
r.getValue(session).getBigDecimal().compareTo(Value.MIN_LONG_DECIMAL) == 0) {
// convert Long.MIN_VALUE to type 'long'
// (Long.MAX_VALUE+1 is of type 'decimal')
r = ValueExpression.get(ValueLong.MIN);
......
......@@ -76,7 +76,7 @@ public class Call extends Prepared {
public void prepare() {
expression = expression.optimize(session);
expressions = new Expression[] { expression };
isResultSet = expression.getValueType() == Value.RESULT_SET;
isResultSet = expression.getType().getValueType() == Value.RESULT_SET;
if (isResultSet) {
prepareAlways = true;
}
......
......@@ -122,7 +122,7 @@ public class SelectUnion extends Query {
Mode mode = session.getDatabase().getMode();
for (int i = 0; i < columnCount; i++) {
Expression e = expressions.get(i);
newValues[i] = values[i].convertTo(e.getValueType(), mode);
newValues[i] = values[i].convertTo(e.getType().getValueType(), mode);
}
return newValues;
}
......
......@@ -42,11 +42,6 @@ public class Alias extends Expression {
return expr.getType();
}
@Override
public int getValueType() {
return expr.getValueType();
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
expr.mapColumns(resolver, level, state);
......
......@@ -60,7 +60,6 @@ public class BinaryOperation extends Expression {
private OpType opType;
private Expression left, right;
private TypeInfo type;
private int dataType;
private boolean convertRight = true;
public BinaryOperation(OpType opType, Expression left, Expression right) {
......@@ -100,6 +99,7 @@ public class BinaryOperation extends Expression {
@Override
public Value getValue(Session session) {
Mode mode = session.getDatabase().getMode();
int dataType = type.getValueType();
Value l = left.getValue(session).convertTo(dataType, mode);
Value r = right.getValue(session);
if (convertRight) {
......@@ -166,15 +166,14 @@ public class BinaryOperation extends Expression {
switch (opType) {
case CONCAT:
type = TypeInfo.TYPE_STRING_DEFAULT;
dataType = Value.STRING;
break;
case PLUS:
case MINUS:
case MULTIPLY:
case DIVIDE:
case MODULUS:
int l = left.getValueType();
int r = right.getValueType();
int l = left.getType().getValueType();
int r = right.getType().getValueType();
if ((l == Value.NULL && r == Value.NULL) ||
(l == Value.UNKNOWN && r == Value.UNKNOWN)) {
// (? + ?) - use decimal by default (the most safe data type) or
......@@ -182,18 +181,16 @@ public class BinaryOperation extends Expression {
if (opType == OpType.PLUS && session.getDatabase().
getMode().allowPlusForStringConcat) {
type = TypeInfo.TYPE_STRING_DEFAULT;
dataType = Value.STRING;
opType = OpType.CONCAT;
} else {
type = TypeInfo.TYPE_DECIMAL_DEFAULT;
dataType = Value.DECIMAL;
}
} else if (DataType.isIntervalType(l) || DataType.isIntervalType(r)) {
return optimizeInterval(session, l, r);
} else if (DataType.isDateTimeType(l) || DataType.isDateTimeType(r)) {
return optimizeDateTime(session, l, r);
} else {
dataType = Value.getHigherOrder(l, r);
int dataType = Value.getHigherOrder(l, r);
if (dataType == Value.ENUM) {
type = TypeInfo.TYPE_INT;
dataType = Value.INT;
......@@ -317,12 +314,10 @@ public class BinaryOperation extends Expression {
}
case Value.TIME:
if (r == Value.TIME || r == Value.TIMESTAMP_TZ) {
dataType = r;
type = TypeInfo.getTypeInfo(r);
return this;
} else { // DATE, TIMESTAMP
type = TypeInfo.TYPE_TIMESTAMP;
dataType = Value.TIMESTAMP;
return this;
}
}
......@@ -361,7 +356,6 @@ public class BinaryOperation extends Expression {
}
case Value.TIME:
type = TypeInfo.TYPE_TIMESTAMP;
dataType = Value.TIMESTAMP;
return this;
case Value.DATE:
case Value.TIMESTAMP:
......@@ -379,13 +373,11 @@ public class BinaryOperation extends Expression {
case MULTIPLY:
if (l == Value.TIME) {
type = TypeInfo.TYPE_TIME;
dataType = Value.TIME;
convertRight = false;
return this;
} else if (r == Value.TIME) {
swap();
type = TypeInfo.TYPE_TIME;
dataType = Value.TIME;
convertRight = false;
return this;
}
......@@ -393,7 +385,6 @@ public class BinaryOperation extends Expression {
case DIVIDE:
if (l == Value.TIME) {
type = TypeInfo.TYPE_TIME;
dataType = Value.TIME;
convertRight = false;
return this;
}
......@@ -425,11 +416,6 @@ public class BinaryOperation extends Expression {
return type;
}
@Override
public int getValueType() {
return dataType;
}
@Override
public void updateAggregate(Session session, int stage) {
left.updateAggregate(session, stage);
......
......@@ -92,14 +92,6 @@ public abstract class Expression {
*/
public abstract TypeInfo getType();
/**
* Return the value type. The value type may not be known before the
* optimization phase.
*
* @return the value type
*/
public abstract int getValueType();
/**
* Map the columns of the resolver to expression columns.
*
......
......@@ -230,11 +230,6 @@ public class ExpressionColumn extends Expression {
return column == null ? TypeInfo.TYPE_UNKNOWN : column.getType();
}
@Override
public int getValueType() {
return column == null ? Value.UNKNOWN : column.getType().getValueType();
}
@Override
public void setEvaluatable(TableFilter tableFilter, boolean b) {
}
......
......@@ -42,11 +42,6 @@ public class ExpressionList extends Expression {
return isArray ? TypeInfo.TYPE_ARRAY : TypeInfo.TYPE_ROW;
}
@Override
public int getValueType() {
return isArray ? Value.ARRAY : Value.ROW;
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
for (Expression e : list) {
......
......@@ -79,7 +79,6 @@ public class IntervalOperation extends Expression {
private final IntervalOpType opType;
private Expression left, right;
private TypeInfo type;
private int dataType;
private static BigInteger nanosFromValue(Value v) {
long[] a = dateAndTimeFromValue(v);
......@@ -91,30 +90,25 @@ public class IntervalOperation extends Expression {
this.opType = opType;
this.left = left;
this.right = right;
int l = left.getValueType(), r = right.getValueType();
int l = left.getType().getValueType(), r = right.getType().getValueType();
switch (opType) {
case INTERVAL_PLUS_INTERVAL:
case INTERVAL_MINUS_INTERVAL:
dataType = Value.getHigherOrder(l, r);
type = TypeInfo.getTypeInfo(dataType);
type = TypeInfo.getTypeInfo(Value.getHigherOrder(l, r));
break;
case DATETIME_PLUS_INTERVAL:
case DATETIME_MINUS_INTERVAL:
case INTERVAL_MULTIPLY_NUMERIC:
case INTERVAL_DIVIDE_NUMERIC:
type = left.getType();
dataType = l;
break;
case DATETIME_MINUS_DATETIME:
if (l == Value.TIME && r == Value.TIME) {
type = TypeInfo.TYPE_INTERVAL_HOUR_TO_SECOND;
dataType = Value.INTERVAL_HOUR_TO_SECOND;
} else if (l == Value.DATE && r == Value.DATE) {
type = TypeInfo.TYPE_INTERVAL_DAY;
dataType = Value.INTERVAL_DAY;
} else {
type = TypeInfo.TYPE_INTERVAL_DAY_TO_SECOND;
dataType = Value.INTERVAL_DAY_TO_SECOND;
}
}
}
......@@ -288,11 +282,6 @@ public class IntervalOperation extends Expression {
return type;
}
@Override
public int getValueType() {
return dataType;
}
@Override
public void updateAggregate(Session session, int stage) {
left.updateAggregate(session, stage);
......
......@@ -38,11 +38,6 @@ public class Rownum extends Expression {
return TypeInfo.TYPE_LONG;
}
@Override
public int getValueType() {
return Value.LONG;
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
// nothing to do
......
......@@ -37,11 +37,6 @@ public class SequenceValue extends Expression {
return TypeInfo.TYPE_LONG;
}
@Override
public int getValueType() {
return Value.LONG;
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
// nothing to do
......
......@@ -58,11 +58,6 @@ public class Subquery extends Expression {
return getExpression().getType();
}
@Override
public int getValueType() {
return getExpression().getValueType();
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
query.mapColumns(resolver, level + 1);
......
......@@ -68,11 +68,6 @@ public class UnaryOperation extends Expression {
return type;
}
@Override
public int getValueType() {
return type.getValueType();
}
@Override
public void updateAggregate(Session session, int stage) {
arg.updateAggregate(session, stage);
......
......@@ -80,11 +80,6 @@ public class ValueExpression extends Expression {
return value.getType();
}
@Override
public int getValueType() {
return value.getValueType();
}
@Override
public void createIndexConditions(Session session, TableFilter filter) {
if (value.getValueType() == Value.BOOLEAN) {
......@@ -168,7 +163,7 @@ public class ValueExpression extends Expression {
@Override
public Expression[] getExpressionColumns(Session session) {
if (getValueType() == Value.ARRAY) {
if (getType().getValueType() == Value.ARRAY) {
return getExpressionColumns(session, (ValueArray) getValue(session));
}
return super.getExpressionColumns(session);
......
......@@ -42,11 +42,6 @@ public class Variable extends Expression {
return lastValue.getType();
}
@Override
public int getValueType() {
return lastValue.getValueType();
}
@Override
public Value getValue(Session session) {
lastValue = session.getVariable(name);
......
......@@ -72,11 +72,6 @@ public class Wildcard extends Expression {
throw DbException.throwInternalError(toString());
}
@Override
public int getValueType() {
throw DbException.throwInternalError(toString());
}
@Override
public void mapColumns(ColumnResolver resolver, int level, int state) {
if (exceptColumns != null) {
......
......@@ -164,7 +164,6 @@ public class Aggregate extends AbstractAggregate {
private ArrayList<SelectOrderBy> orderByList;
private SortOrder orderBySort;
private TypeInfo type;
private int dataType;
/**
* Create a new aggregate object.
......@@ -304,7 +303,7 @@ public class Aggregate extends AbstractAggregate {
v = updateCollecting(session, v, remembered);
}
}
data.add(session.getDatabase(), dataType, v);
data.add(session.getDatabase(), type.getValueType(), v);
}
@Override
......@@ -410,7 +409,7 @@ public class Aggregate extends AbstractAggregate {
return v;
}
case MEDIAN:
return AggregateMedian.medianFromIndex(session, on, dataType);
return AggregateMedian.medianFromIndex(session, on, type.getValueType());
case ENVELOPE:
return ((MVSpatialIndex) AggregateDataEnvelope.getGeometryColumnIndex(on)).getBounds(session);
default:
......@@ -443,6 +442,7 @@ public class Aggregate extends AbstractAggregate {
}
AggregateDataDefault d = new AggregateDataDefault(aggregateType);
Database db = session.getDatabase();
int dataType = type.getValueType();
for (Value v : c) {
d.add(db, dataType, v);
}
......@@ -473,14 +473,14 @@ public class Aggregate extends AbstractAggregate {
if (array == null) {
return ValueNull.INSTANCE;
}
return AggregateMedian.median(session.getDatabase(), array, dataType);
return AggregateMedian.median(session.getDatabase(), array, type.getValueType());
}
case MODE:
return getMode(session, data);
default:
// Avoid compiler warning
}
return data.getValue(session.getDatabase(), dataType);
return data.getValue(session.getDatabase(), type.getValueType());
}
private Value getGroupConcat(Session session, AggregateData data) {
......@@ -573,7 +573,7 @@ public class Aggregate extends AbstractAggregate {
}
}
}
return v.convertTo(dataType);
return v.convertTo(type.getValueType());
}
@Override
......@@ -581,11 +581,6 @@ public class Aggregate extends AbstractAggregate {
return type;
}
@Override
public int getValueType() {
return dataType;
}
@Override
public void mapColumnsAnalysis(ColumnResolver resolver, int level, int innerState) {
if (on != null) {
......@@ -608,7 +603,6 @@ public class Aggregate extends AbstractAggregate {
if (on != null) {
on = on.optimize(session);
type = on.getType();
dataType = on.getValueType();
}
if (orderByList != null) {
for (SelectOrderBy o : orderByList) {
......@@ -622,35 +616,31 @@ public class Aggregate extends AbstractAggregate {
switch (aggregateType) {
case GROUP_CONCAT:
type = TypeInfo.TYPE_STRING_DEFAULT;
dataType = Value.STRING;
break;
case COUNT_ALL:
case COUNT:
type = TypeInfo.TYPE_LONG;
dataType = Value.LONG;
break;
case SELECTIVITY:
type = TypeInfo.TYPE_INT;
dataType = Value.INT;
break;
case HISTOGRAM:
type = TypeInfo.TYPE_ARRAY;
dataType = Value.ARRAY;
break;
case SUM:
case SUM: {
int dataType = type.getValueType();
if (dataType == Value.BOOLEAN) {
// example: sum(id > 3) (count the rows)
type = TypeInfo.TYPE_LONG;
dataType = Value.LONG;
} else if (!DataType.supportsAdd(dataType)) {
throw DbException.get(ErrorCode.SUM_OR_AVG_ON_WRONG_DATATYPE_1, getSQL());
} else {
dataType = DataType.getAddProofType(dataType);
type = TypeInfo.getTypeInfo(dataType);
type = TypeInfo.getTypeInfo(DataType.getAddProofType(dataType));
}
break;
}
case AVG:
if (!DataType.supportsAdd(dataType)) {
if (!DataType.supportsAdd(type.getValueType())) {
throw DbException.get(ErrorCode.SUM_OR_AVG_ON_WRONG_DATATYPE_1, getSQL());
}
break;
......@@ -664,26 +654,22 @@ public class Aggregate extends AbstractAggregate {
case VAR_POP:
case VAR_SAMP:
type = TypeInfo.TYPE_DOUBLE;
dataType = Value.DOUBLE;
break;
case EVERY:
case ANY:
type = TypeInfo.TYPE_BOOLEAN;
dataType = Value.BOOLEAN;
break;
case BIT_AND:
case BIT_OR:
if (!DataType.supportsAdd(dataType)) {
if (!DataType.supportsAdd(type.getValueType())) {
throw DbException.get(ErrorCode.SUM_OR_AVG_ON_WRONG_DATATYPE_1, getSQL());
}
break;
case ARRAY_AGG:
type = TypeInfo.TYPE_ARRAY;
dataType = Value.ARRAY;
break;
case ENVELOPE:
type = TypeInfo.TYPE_GEOMETRY;
dataType = Value.GEOMETRY;
break;
default:
DbException.throwInternalError("type=" + aggregateType);
......
......@@ -67,11 +67,6 @@ public class JavaAggregate extends AbstractAggregate {
return type;
}
@Override
public int getValueType() {
return dataType;
}
@Override
public boolean isEverything(ExpressionVisitor visitor) {
if (!super.isEverything(visitor)) {
......@@ -114,7 +109,7 @@ public class JavaAggregate extends AbstractAggregate {
for (int i = 0; i < len; i++) {
Expression expr = args[i];
args[i] = expr.optimize(session);
int type = expr.getValueType();
int type = expr.getType().getValueType();
argTypes[i] = type;
}
try {
......
......@@ -287,7 +287,7 @@ public class WindowFunction extends DataAnalysisOperation {
int rowIdColumn) {
int size = ordered.size();
int numExpressions = getNumExpressions();
int dataType = args[0].getValueType();
int dataType = args[0].getType().getValueType();
for (int i = 0; i < size; i++) {
Value[] row = ordered.get(i);
int rowId = row[rowIdColumn].getInt();
......@@ -498,29 +498,6 @@ public class WindowFunction extends DataAnalysisOperation {
}
}
@Override
public int getValueType() {
switch (type) {
case ROW_NUMBER:
case RANK:
case DENSE_RANK:
case NTILE:
return Value.LONG;
case PERCENT_RANK:
case CUME_DIST:
case RATIO_TO_REPORT:
return Value.DOUBLE;
case LEAD:
case LAG:
case FIRST_VALUE:
case LAST_VALUE:
case NTH_VALUE:
return args[0].getValueType();
default:
throw DbException.throwInternalError("type=" + type);
}
}
@Override
public StringBuilder getSQL(StringBuilder builder) {
String name = type.getSQL();
......
......@@ -100,7 +100,7 @@ public class CompareLike extends Condition {
public Expression optimize(Session session) {
left = left.optimize(session);
right = right.optimize(session);
if (left.getValueType() == Value.STRING_IGNORECASE) {
if (left.getType().getValueType() == Value.STRING_IGNORECASE) {
ignoreCase = true;
}
if (left.isValueSet()) {
......
......@@ -206,7 +206,7 @@ public class Comparison extends Condition {
if (right != null) {
right = right.optimize(session);
// TODO check row values too
if (right.getValueType() == Value.ARRAY && left.getValueType() != Value.ARRAY) {
if (right.getType().getValueType() == Value.ARRAY && left.getType().getValueType() != Value.ARRAY) {
throw DbException.get(ErrorCode.COMPARING_ARRAY_TO_SCALAR);
}
if (right instanceof ExpressionColumn) {
......@@ -225,7 +225,7 @@ public class Comparison extends Condition {
return ValueExpression.getNull();
}
}
int colType = left.getValueType();
int colType = left.getType().getValueType();
int constType = r.getValueType();
int resType = Value.getHigherOrder(colType, constType);
// If not, the column values will need to be promoted
......@@ -516,12 +516,14 @@ public class Comparison extends Condition {
}
if (addIndex) {
if (l != null) {
if (l.getValueType() == right.getValueType() || right.getValueType() != Value.STRING_IGNORECASE) {
int rType = right.getType().getValueType();
if (l.getType().getValueType() == rType || rType != Value.STRING_IGNORECASE) {
filter.addIndexCondition(
IndexCondition.get(compareType, l, right));
}
} else if (r != null) {
if (r.getValueType() == left.getValueType() || left.getValueType() != Value.STRING_IGNORECASE) {
int lType = left.getType().getValueType();
if (r.getType().getValueType() == lType || lType != Value.STRING_IGNORECASE) {
int compareRev = getReversedCompareType(compareType);
filter.addIndexCondition(
IndexCondition.get(compareRev, r, left));
......
......@@ -7,7 +7,6 @@ package org.h2.expression.condition;
import org.h2.expression.Expression;
import org.h2.value.TypeInfo;
import org.h2.value.Value;
/**
* Represents a condition returning a boolean value, or NULL.
......@@ -19,9 +18,4 @@ abstract class Condition extends Expression {
return TypeInfo.TYPE_BOOLEAN;
}
@Override
public int getValueType() {
return Value.BOOLEAN;
}
}
......@@ -150,7 +150,7 @@ public class ConditionIn extends Condition {
return new Comparison(session, Comparison.EQUAL, left, values.get(0)).optimize(session);
}
if (allValuesConstant && !allValuesNull) {
int leftType = left.getValueType();
int leftType = left.getType().getValueType();
if (leftType == Value.UNKNOWN) {
return this;
}
......
......@@ -54,7 +54,7 @@ public class ConditionInConstantSet extends Condition {
this.valueList = valueList;
Database database = session.getDatabase();
this.valueSet = new TreeSet<>(database.getCompareMode());
type = left.getValueType();
type = left.getType().getValueType();
Mode mode = database.getMode();
if (type == Value.ENUM) {
extTypeInfo = ((ExpressionColumn) left).getColumn().getType().getExtTypeInfo();
......
......@@ -2327,7 +2327,7 @@ public class Function extends Expression implements FunctionCall {
s = ValueTimestamp.MAXIMUM_SCALE;
if (p0.isConstant()) {
Expression p2 = args[2];
switch (p2.getValueType()) {
switch (p2.getType().getValueType()) {
case Value.TIME:
t = Value.TIME;
p = d = ValueTime.DEFAULT_PRECISION;
......@@ -2374,7 +2374,7 @@ public class Function extends Expression implements FunctionCall {
}
case DATE_TRUNC: {
Expression p1 = args[1];
t = p1.getValueType();
t = p1.getType().getValueType();
if (t == Value.TIMESTAMP_TZ) {
p = d = ValueTimestampTimeZone.DEFAULT_PRECISION;
} else {
......@@ -2466,18 +2466,18 @@ public class Function extends Expression implements FunctionCall {
break;
}
case NVL2: {
switch (args[1].getValueType()) {
TypeInfo t1 = args[1].getType(), t2 = args[2].getType();
switch (t1.getValueType()) {
case Value.STRING:
case Value.CLOB:
case Value.STRING_FIXED:
case Value.STRING_IGNORECASE:
t = args[1].getValueType();
t = t1.getValueType();
break;
default:
t = Value.getHigherOrder(args[1].getValueType(), args[2].getValueType());
t = Value.getHigherOrder(t1.getValueType(), t2.getValueType());
break;
}
TypeInfo t1 = args[1].getType(), t2 = args[2].getType();
p = Math.max(t1.getPrecision(), t2.getPrecision());
d = Math.max(t1.getDisplaySize(), t2.getDisplaySize());
s = Math.max(t1.getScale(), t2.getScale());
......@@ -2498,7 +2498,7 @@ public class Function extends Expression implements FunctionCall {
}
break;
case TRUNCATE:
switch (p0.getValueType()) {
switch (p0.getType().getValueType()) {
case Value.STRING:
case Value.DATE:
case Value.TIMESTAMP:
......
......@@ -24,6 +24,7 @@ import org.h2.table.IndexColumn;
import org.h2.table.Table;
import org.h2.util.TempFileDeleter;
import org.h2.value.DataType;
import org.h2.value.TypeInfo;
import org.h2.value.Value;
import org.h2.value.ValueNull;
......@@ -117,9 +118,9 @@ public class ResultTempTable implements ResultExternal {
CreateTableData data = new CreateTableData();
boolean containsLob = false;
for (int i = 0; i < expressions.length; i++) {
int type = expressions[i].getValueType();
TypeInfo type = expressions[i].getType();
Column col = new Column(COLUMN_NAME + i, type);
if (DataType.isLargeObject(type)) {
if (DataType.isLargeObject(type.getValueType())) {
containsLob = true;
}
data.columns.add(col);
......
......@@ -1762,7 +1762,7 @@ public class MetaTable extends Table {
// CONSTANT_NAME
identifier(constant.getName()),
// DATA_TYPE
ValueInt.get(DataType.convertTypeToSQLType(expr.getValueType())),
ValueInt.get(DataType.convertTypeToSQLType(expr.getType().getValueType())),
// REMARKS
replaceNullWithEmpty(constant.getComment()),
// SQL
......
......@@ -192,7 +192,7 @@ public class TableView extends Table {
}
name = columnNamer.getColumnName(expr, i, name);
if (valueType == Value.UNKNOWN) {
valueType = expr.getValueType();
valueType = expr.getType().getValueType();
}
TypeInfo type = expr.getType();
long precision = type.getPrecision();
......@@ -819,8 +819,7 @@ public class TableView extends Table {
// (if found) otherwise use column name derived from column
// expression
String columnName = columnNamer.getColumnName(columnExp, i, cols);
columnTemplateList.add(new Column(columnName,
columnExp.getValueType()));
columnTemplateList.add(new Column(columnName, columnExp.getType()));
}
return columnTemplateList;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论