Github user huor commented on a diff in the pull request:

    https://github.com/apache/incubator-hawq/pull/1384#discussion_r208434607
  
    --- Diff: src/backend/cdb/cdbdatalocality.c ---
    @@ -844,36 +918,17 @@ int64 
get_block_locations_and_claculte_table_size(split_to_segment_mapping_conte
                /*
                 * We only consider the data stored in HDFS.
                 */
    -           if (RelationIsAoRows(rel) || RelationIsParquet(rel)) {
    -                   Relation_Data *rel_data = NULL;
    -                   /*
    -                    * Get pg_appendonly information for this table.
    -                    */
    -                   AppendOnlyEntry *aoEntry = GetAppendOnlyEntry(rel_oid, 
SnapshotNow);
    -
    -                   rel_data = (Relation_Data *) 
palloc(sizeof(Relation_Data));
    +           bool isDataStoredInHdfs = dataStoredInHdfs(rel);
    --- End diff --
    
    Should keep the logic to get block location for AO and Parquet, need to add 
branch to get block location for external table that store data on HDFS.


---

Reply via email to