15 package com.cloudera.impala.analysis;
17 import org.apache.hadoop.hive.metastore.MetaStoreUtils;
21 import com.cloudera.impala.thrift.TColumn;
22 import com.google.common.base.Preconditions;
55 if (!MetaStoreUtils.validateName(
colName_)) {
56 throw new AnalysisException(
"Invalid column/field name: " +
colName_);
59 typeDef_.analyze(null);
60 type_ = typeDef_.getType();
62 Preconditions.checkNotNull(
type_);
63 Preconditions.checkState(type_.isValid());
68 StringBuilder sb =
new StringBuilder(
colName_);
70 sb.append(
" " + type_.toString());
72 sb.append(
" " + typeDef_.toString());
ColumnDef(String colName, TypeDef typeDef, String comment)