Package org.apache.pig.impl.eval

Examples of org.apache.pig.impl.eval.ConstSpec


        //Constructing the query structures by hand, quite ugly.
       
        //group all
        ArrayList<EvalSpec> groupFuncs = new ArrayList<EvalSpec>();
   
        groupFuncs.add(new GenerateSpec(new ConstSpec("all")).getGroupBySpec());
   
        quantileJob.groupFuncs = groupFuncs;
       
        //find the quantiles in the reduce step
        ArrayList<EvalSpec> argsList = new ArrayList<EvalSpec>();
        argsList.add(new ConstSpec(Math.max(loSort.getRequestedParallelism()-1,1)));
       
        //sort the first column of the cogroup output and feed it to the quantiles function
        EvalSpec sortedSampleSpec = new ProjectSpec(1);
        EvalSpec starSpec = new StarSpec();
        starSpec.setComparatorName(loSort.getSortSpec().getComparatorName());
View Full Code Here

TOP

Related Classes of org.apache.pig.impl.eval.ConstSpec

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.