public String getAlterTableAddPartition(Partition pt) {
    Table tb = pt.getTable();
    ST command = new ST(ALTER_TABLE_CREATE_PARTITION);
    command.add(DATABASE_NAME, unparseIdentifier(tb.getDbName()));
    command.add(TABLE_NAME, unparseIdentifier(tb.getTableName()));
    command.add(PARTITION, getPartitionActualName(pt));
    if (checkIfDefaultPartition(pt.getName())) {
      command.add(COMMENT_SQL, "--");
    }
    return command.render();
  }
Creates the alter table command to add a partition to the given table.

@param pt
@return
ql/src/java/org/apache/hadoop/hive/ql/exec/DDLPlanUtils.java