protected void appendColumns(StringBuilder query, List<FieldSchema> cols, boolean alias) {
    if (cols == null) {
      throw new IllegalStateException("Query could not be created: Source columns are unknown");
    }
    for (int i = 0; i < cols.size(); ++i) {
      if (alias) {
        query.append(i == 0 ? "'" : ", '").append(cols.get(i).getName()).append("', `").append(cols.get(i).getName())
            .append("`");
      } else {
        query.append(i == 0 ? "`" : ", `").append(cols.get(i).getName()).append("`");
      }
    }
  }
Part of Create operation. All tmp tables are not transactional and are marked as
compaction tables. Additionally...
- Crud compaction temp tables need tblproperty, "compactiontable."
- Minor crud compaction temp tables need bucketing version tblproperty, if table is bucketed.
ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/CompactionQueryBuilder.java