Package org.apache.derbyTesting.junit

Examples of org.apache.derbyTesting.junit.RuntimeStatisticsParser.usedTableScan()


                { "4", "-8", "4", "4" }, { "4", "-8", "4", "16" },
                { "4", "8", "4", "4" }, { "4", "8", "4", "16" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected table scan", p.usedTableScan());
        assertTrue("Expected hash join", p.usedHashJoin());


        rs = st
                .executeQuery("select * from (select * from t1 union all select * "
 
View Full Code Here


                { "3", "6", "3", "12" }, { "4", "-8", "4", "4" },
                { "4", "-8", "4", "16" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected table scan", p.usedTableScan());
        assertTrue("Expected hash join", p.usedHashJoin());

        rs = st
                .executeQuery("select * from (select * from t1 union select * from "
                        + "t2) x1, (select * from t3 union all select * from "
View Full Code Here

                { "4", "-8", "4", "4" }, { "4", "-8", "4", "16" },
                { "4", "8", "4", "4" }, { "4", "8", "4", "16" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected table scan", p.usedTableScan());
        assertTrue("Expected hash join", p.usedHashJoin());


        rs = st
                .executeQuery("select * from (select * from t1 union all select * "
 
View Full Code Here

                { "3", "6", "3", "12" }, { "4", "-8", "4", "4" },
                { "4", "-8", "4", "16" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected table scan", p.usedTableScan());
        assertTrue("Expected hash join", p.usedHashJoin());

        // Next set of queries tests pushdown of predicates whose
        // column references do not reference base tables--ex. they
        // reference literals, aggregates, or subqueries. We don't
View Full Code Here

        expRS = new String[][] { { "404" } };

        JDBC.assertFullResultSet(rs, expRS, true);
       
        p = SQLUtilities.getRuntimeStatisticsParser(st)
        assertTrue("Expected table scan on T3", p.usedTableScan("T3"));
        assertTrue("Expected table scan on T4", p.usedTableScan("T4"));
     
        rs = st.executeQuery("select count(*) from V1, V2 where V1.j > 0");

        expColNames = new String[] { "1" };
View Full Code Here

        JDBC.assertFullResultSet(rs, expRS, true);
       
        p = SQLUtilities.getRuntimeStatisticsParser(st)
        assertTrue("Expected table scan on T3", p.usedTableScan("T3"));
        assertTrue("Expected table scan on T4", p.usedTableScan("T4"));
     
        rs = st.executeQuery("select count(*) from V1, V2 where V1.j > 0");

        expColNames = new String[] { "1" };
        JDBC.assertColumnNames(rs, expColNames);
View Full Code Here

        expRS = new String[][] { { "505" } };

        JDBC.assertFullResultSet(rs, expRS, true);
    
        p = SQLUtilities.getRuntimeStatisticsParser(st)
        assertTrue("Expected table scan on T3", p.usedTableScan("T3"));
        assertTrue("Expected table scan on T4", p.usedTableScan("T4"));
     
        // Combination of join predicate and non-join predicate:
        // the join predicate should be pushed to V2 (T3 and T4),
        // the non-join predicate should operate as usual.
View Full Code Here

        JDBC.assertFullResultSet(rs, expRS, true);
    
        p = SQLUtilities.getRuntimeStatisticsParser(st)
        assertTrue("Expected table scan on T3", p.usedTableScan("T3"));
        assertTrue("Expected table scan on T4", p.usedTableScan("T4"));
     
        // Combination of join predicate and non-join predicate:
        // the join predicate should be pushed to V2 (T3 and T4),
        // the non-join predicate should operate as usual.
View Full Code Here

                { "3", "6", "3", "3" }, { "4", "-8", "4", "4" },
                { "4", "8", "4", "4" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected Table Scan ResultSet for T1", p.usedTableScan("T1"));
        assertTrue("Expected Table Scan ResultSet for T2", p.usedTableScan("T2"));
       
        // UNION
        // ALL should behave just like normal UNION. I.e.
        // predicates should still be pushed to T3 and T4.
View Full Code Here

                { "4", "8", "4", "4" } };

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        assertTrue("Expected Table Scan ResultSet for T1", p.usedTableScan("T1"));
        assertTrue("Expected Table Scan ResultSet for T2", p.usedTableScan("T2"));
       
        // UNION
        // ALL should behave just like normal UNION. I.e.
        // predicates should still be pushed to T3 and T4.
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.