Package com.facebook.presto.util

Examples of com.facebook.presto.util.MaterializedResult


                },
                ImmutableList.of(singleColumn(VARCHAR, 0), new Add5Projection(1)));

        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult expected = MaterializedResult.resultBuilder(driverContext.getSession(), VARCHAR, BIGINT)
                .row("10", 15)
                .row("11", 16)
                .row("12", 17)
                .row("13", 18)
                .row("14", 19)
View Full Code Here


                                                                                                                        ImmutableList.of("g")}));

        OperatorContext operatorContext = driverContext.addOperatorContext(0, RecordProjectOperator.class.getSimpleName());
        Operator operator = new RecordProjectOperator(operatorContext, records);

        MaterializedResult expected = resultBuilder(driverContext.getSession(), VARCHAR)
                .row("abc")
                .row("def")
                .row("g")
                .build();
View Full Code Here

                ImmutableList.of("g", 0L)));

        OperatorContext operatorContext = driverContext.addOperatorContext(0, RecordProjectOperator.class.getSimpleName());
        Operator operator = new RecordProjectOperator(operatorContext, records);

        MaterializedResult expected = resultBuilder(driverContext.getSession(), VARCHAR, BIGINT)
                .row("abc", 1)
                .row("def", 2)
                .row("g", 0)
                .build();
View Full Code Here

                Ints.asList(0));

        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, BIGINT, BIGINT, VARCHAR, BIGINT, BIGINT)
                .row("20", 1020, 2020, "20", 30, 40)
                .row("21", 1021, 2021, "21", 31, 41)
                .row("22", 1022, 2022, "22", 32, 42)
                .row("23", 1023, 2023, "23", 33, 43)
                .row("24", 1024, 2024, "24", 34, 44)
View Full Code Here

                ImmutableList.of(VARCHAR),
                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, VARCHAR)
                .row("a", "a")
                .row("a", "a")
                .row("b", "b")
                .build();
View Full Code Here

                ImmutableList.of(VARCHAR),
                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, VARCHAR)
                .row("a", "a")
                .row("a", "a")
                .row("b", "b")
                .build();
View Full Code Here

                ImmutableList.of(VARCHAR),
                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, VARCHAR)
                .row("a", "a")
                .row("a", "a")
                .row("b", "b")
                .build();
View Full Code Here

                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, BIGINT, BIGINT, VARCHAR, BIGINT, BIGINT)
                .row("20", 1020, 2020, "20", 30, 40)
                .row("21", 1021, 2021, "21", 31, 41)
                .row("22", 1022, 2022, "22", 32, 42)
                .row("23", 1023, 2023, "23", 33, 43)
                .row("24", 1024, 2024, "24", 34, 44)
View Full Code Here

                ImmutableList.of(VARCHAR),
                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, VARCHAR)
                .row("a", "a")
                .row(null, null)
                .row(null, null)
                .row("a", "a")
                .row("b", "b")
View Full Code Here

                ImmutableList.of(VARCHAR),
                Ints.asList(0));
        Operator joinOperator = joinOperatorFactory.createOperator(taskContext.addPipelineContext(true, true).addDriverContext());

        // expected
        MaterializedResult expected = MaterializedResult.resultBuilder(taskContext.getSession(), VARCHAR, VARCHAR)
                .row("a", "a")
                .row("a", "a")
                .row("b", "b")
                .row("c", null)
                .build();
View Full Code Here

TOP

Related Classes of com.facebook.presto.util.MaterializedResult

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.