private void setUserSpecifiedLocation(Table table) {
    if (desc.getLocation() != null) {
      table.setDataLocation(new Path(desc.getLocation()));
    } else {
      table.unsetDataLocation();
    }
  }
Operation process of creating a table like an existing one.
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/create/like/CreateTableLikeOperation.java