Package org.voltdb.plannodes

Examples of org.voltdb.plannodes.AbstractPlanNode.toExplainPlanString()


        // Negative case
        pn = compile("select * from l WHERE CASE WHEN a < 10 THEN a*2 ELSE a + 5 END > 2");
        pn = pn.getChild(0);
        System.out.println(pn.toExplainPlanString());
        assertTrue(pn.toExplainPlanString().contains("using its primary key index (for deterministic order only)"));
    }
}
View Full Code Here


    //TODO: Not sure what this has to do with PushDownAggregates -- move this test case?
    public void testSinglePartOffset()
    {
        AbstractPlanNode pn = compile("select PKEY from T1 order by PKEY limit 5 offset 1");
        assertTrue(pn.toExplainPlanString().contains("LIMIT"));
    }

    public void testMultiPartOffset() {
        List<AbstractPlanNode> pn = compileToFragments("select PKEY from T1 order by PKEY limit 5 offset 1");
        assertEquals(2, pn.size());
View Full Code Here

        // Find scan node.
        p = pns.get(1);
        assert (p.getScanNodeList().size() == 1);
        p = p.getScanNodeList().get(0);
        String scanNodeStr = p.toExplainPlanString().toLowerCase();

        if (aggFilters != null) {
            String[] aggFilterStrings = null;
            if (aggFilters instanceof String) {
                aggFilterStrings = new String[] { (String) aggFilters };
View Full Code Here

    private void checkReverseScan(String indexName, IndexLookupType lookupType,
            int searchKeys, int endKeys, int predicates, int initials, boolean artificial,
            SortDirectionType sortType, boolean needOrderby) {

        AbstractPlanNode pn = compile(sql);
        System.out.println(pn.toExplainPlanString());

        assertTrue(pn instanceof SendPlanNode);
        pn = pn.getChild(0);
        if (needOrderby) {
            assertTrue(pn instanceof ProjectionPlanNode);
View Full Code Here

    }

    private void checkForwardScan(String indexName, IndexLookupType lookupType,
            int searchKeys, int endKeys, int predicates, SortDirectionType sortType, boolean needOrderby) {
        AbstractPlanNode pn = compile(sql);
        System.out.println(pn.toExplainPlanString());

        assertTrue(pn instanceof SendPlanNode);
        pn = pn.getChild(0);

        if (needOrderby) {
View Full Code Here

            p = pns.get(1).getChild(0);
            assertTrue(p instanceof OrderByPlanNode);
            assertNotNull(p.getInlinePlanNode(PlanNodeType.LIMIT));
        } else if (pns.size() == 2) {
            p = pns.get(1).getChild(0);
            assertFalse(p.toExplainPlanString().toLowerCase().contains("limit"));
        }
    }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.