hawq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shivzone <...@git.apache.org>
Subject [GitHub] incubator-hawq pull request: Analyze HAWQ-44
Date Thu, 12 Nov 2015 23:18:49 GMT
Github user shivzone commented on a diff in the pull request:

    https://github.com/apache/incubator-hawq/pull/92#discussion_r44730180
  
    --- Diff: pxf/pxf-service/src/main/java/org/apache/hawq/pxf/service/BridgeOutputBuilder.java
---
    @@ -216,10 +245,53 @@ void fillText(List<OneField> recFields) throws BadRecordException
{
             int type = fld.type;
             Object val = fld.val;
             if (DataType.get(type) == DataType.BYTEA) {// from LineBreakAccessor
    -            output = new BufferWritable((byte[]) val);
    +            if (samplingEnabled) {
    +                convertTextDataToLines((byte[]) val);
    +            } else {
    +                output = new BufferWritable((byte[]) val);
    +                outputList.add(output); // TODO break output into lines
    +            }
             } else { // from QuotedLineBreakAccessor
                 String textRec = (String) val;
                 output = new Text(textRec + "\n");
    +            outputList.add(output);
    +        }
    +    }
    +
    +    void convertTextDataToLines(byte[] val) {
    --- End diff --
    
    Add a comment to this function explaining the purpose of this either here or when it is
invoked for sampling


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message