Package org.apache.derbyTesting.junit

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


                    SQLUtilities.getRuntimeStatisticsParser(s);
            // Before DERBY-4204 the assert below would fail for some kinds
            // of statements because the statistics for the previous call to
            // SYSCS_GET_RUNTIMESTATISTICS() would be returned instead of the
            // statistics for the previously executed statement.
            assertTrue("Wrong statement", rtsp.findString(sql, 1));
        }
        if (schema != null)
        {
            // Before DERBY-4204, we would only get a single row for some
            // kinds of statements, because the statistics weren't re-captured.
View Full Code Here


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

        JDBC.assertFullResultSet(rs, expRS, true);
        p = SQLUtilities.getRuntimeStatisticsParser(st);
        // Expect to see scalar qualifiers with <= operator for four scans.
        p.findString("Operator: <=", 4);
        //  In this
        // case there are no qualifiers, but the restriction is
        // enforced at the ProjectRestrictNode level. That hasn't
        // changed with DERBY-805.
View Full Code Here

                "and t1.twenty = t2.twenty and " +
                "t2.two = t3.two").close();
        checkEstimatedRowCount(conn,1.606007503125E7);
        RuntimeStatisticsParser rtsp =
                SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 2, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 2, 3}", 1));
        assertTrue(rtsp.findString(
                "Hash Scan ResultSet for T3 using index T3_TWO_TWENTY", 1));
View Full Code Here

                "t2.two = t3.two").close();
        checkEstimatedRowCount(conn,1.606007503125E7);
        RuntimeStatisticsParser rtsp =
                SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 2, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 2, 3}", 1));
        assertTrue(rtsp.findString(
                "Hash Scan ResultSet for T3 using index T3_TWO_TWENTY", 1));
       
View Full Code Here

        checkEstimatedRowCount(conn,1.606007503125E7);
        RuntimeStatisticsParser rtsp =
                SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 2, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 2, 3}", 1));
        assertTrue(rtsp.findString(
                "Hash Scan ResultSet for T3 using index T3_TWO_TWENTY", 1));
       
        // t1 x t2 -> 16 * 10^4.
 
View Full Code Here

        RuntimeStatisticsParser rtsp =
                SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 2, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 2, 3}", 1));
        assertTrue(rtsp.findString(
                "Hash Scan ResultSet for T3 using index T3_TWO_TWENTY", 1));
       
        // t1 x t2 -> 16 * 10^4.
        // x t3    -> 32 * 10^7
 
View Full Code Here

                SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 2, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 2, 3}", 1));
        assertTrue(rtsp.findString(
                "Hash Scan ResultSet for T3 using index T3_TWO_TWENTY", 1));
       
        // t1 x t2 -> 16 * 10^4.
        // x t3    -> 32 * 10^7
        // additional pred -> 32 * 10^5
 
View Full Code Here

                "where t1.hundred = t2.hundred " +
                "and t2.two = t3.two and " +
                "t1.hundred = t3.hundred").close();
        checkEstimatedRowCount(conn,3212015.00625);
        rtsp = SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T3", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
View Full Code Here

                "and t2.two = t3.two and " +
                "t1.hundred = t3.hundred").close();
        checkEstimatedRowCount(conn,3212015.00625);
        rtsp = SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T3", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
       
View Full Code Here

                "t1.hundred = t3.hundred").close();
        checkEstimatedRowCount(conn,3212015.00625);
        rtsp = SQLUtilities.getRuntimeStatisticsParser(s);
        assertTrue(rtsp.findString("Table Scan ResultSet for T1", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={0, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T2", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
        assertTrue(rtsp.findString("Hash Scan ResultSet for T3", 1));
        assertTrue(rtsp.findString("Bit set of columns fetched={1, 3}", 1));
       
        // variations on above query; try different join strategies
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.