private Set<PartitionFieldNode> parse(List<String> inputProjectionFields) throws MetaException {
    // in case of dbName and tableName we rely on table object to get their values
    this.projectionFields = new HashSet<>(inputProjectionFields);
    projectionFields.remove("dbName");
    projectionFields.remove("tableName");
    projectionFields.remove("catName");
    if (isView) {
      // if this is a view SDs are not set so can be skipped
      projectionFields.removeIf(
          s -> s.matches(SD_PATTERN) || s.matches(SERDE_PATTERN) || s.matches(CD_PATTERN));
    }
    // remove redundant fields
    projectionFields = PartitionProjectionEvaluator.expand(projectionFields);
    removeUnsupportedFields();
    validate(projectionFields);

    Map<String, PartitionFieldNode> nestedNodes = new HashMap<>();
    Set<PartitionFieldNode> rootNodes = new HashSet<>();

    for (String projectedField : projectionFields) {
      String[] fields = projectedField.split("\\.");
      if (fields.length == 0) {
        LOG.warn("Invalid projected field {}. Ignoring ..", projectedField);
        continue;
      }
      StringBuilder fieldNameBuilder = new StringBuilder(fields[0]);
      PartitionFieldNode currentNode = createIfNotExists(nestedNodes, fieldNameBuilder.toString());
      rootNodes.add(currentNode);
      for (int level = 1; level < fields.length; level++) {
        final String name = fieldNameBuilder.append(".").append(fields[level]).toString();
        PartitionFieldNode childNode = createIfNotExists(nestedNodes, name);
        // all the children of a multi-valued nodes are also multi-valued
        if (currentNode.isMultiValued) {
          childNode.setMultiValued();
        }
        currentNode.addChild(childNode);
        currentNode = childNode;
      }
    }
    return rootNodes;
  }
if top level field name is given expand the top level field such that all the children
of that node are added to the projection list. eg. if only "sd" is provided in the projection
list, it means all the nested fields for sd should be added to the projection fields
@param projectionList
@return
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/PartitionProjectionEvaluator.java