public class OEChecks
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.sql.Connection |
conn |
private HandleCheckError |
errorHandler
How to report an error.
|
private short |
scale
Warehouse scaling factor
|
Constructor and Description |
---|
OEChecks() |
Modifier and Type | Method and Description |
---|---|
void |
checkAllRowCounts()
Return suite of tests that OEChecks the row counts for all the tables in
the Order Entry bechmark.
|
private void |
checkCountStar(java.lang.String table,
int expected)
Check if number of rows in table is as expected
|
private void |
checkWithinOnePercent(java.lang.String tableName,
int expected)
Check if number of rows in table is within one percent of expected value
|
void |
initialize(HandleCheckError errorHandler,
java.sql.Connection conn,
short scale) |
private int |
rowsInTable(java.lang.String tableName)
Return the number of rows in the table.
|
void |
testCustomerRows()
Test cardinality of CUSTOMER table
|
void |
testDistrictRows()
Test cardinality of DISTRICT table
|
void |
testHistoryRows()
Test cardinality of HISTORY table
|
void |
testItemRows()
Test cardinality of ITEM table
|
void |
testNewOrdersRows()
Test cardinality of NEWORDERS table
|
void |
testOrderLineRows()
Test cardinality of ORDERLINE table
|
void |
testOrdersRows()
Test cardinality of ORDERS table
|
void |
testStockRows()
Test cardinality of STOCK table
|
void |
testWarehouseRows()
Test cardinality of WAREHOUSE table
|
private HandleCheckError errorHandler
private short scale
private java.sql.Connection conn
public void initialize(HandleCheckError errorHandler, java.sql.Connection conn, short scale) throws java.lang.Exception
java.lang.Exception
public void checkAllRowCounts() throws java.lang.Exception
java.lang.Exception
public void testWarehouseRows() throws java.lang.Exception
java.lang.Exception
public void testStockRows() throws java.lang.Exception
java.lang.Exception
public void testOrdersRows() throws java.lang.Exception
java.lang.Exception
public void testDistrictRows() throws java.lang.Exception
java.lang.Exception
public void testCustomerRows() throws java.lang.Exception
java.lang.Exception
public void testItemRows() throws java.lang.Exception
java.lang.Exception
public void testNewOrdersRows() throws java.lang.Exception
java.lang.Exception
public void testHistoryRows() throws java.lang.Exception
java.lang.Exception
public void testOrderLineRows() throws java.lang.Exception
java.lang.Exception
private void checkCountStar(java.lang.String table, int expected) throws java.lang.Exception
table
- -
table on which to execute the queryexpected
- -
expected number of rowsjava.lang.Exception
private int rowsInTable(java.lang.String tableName) throws java.sql.SQLException
tableName
- -
name of the tablejava.sql.SQLException
private void checkWithinOnePercent(java.lang.String tableName, int expected) throws java.lang.Exception
tableName
- -
table on which to execute the queryexpected
- -
expected number of rowsjava.lang.Exception
Apache Derby V10.13 Internals - Copyright © 2004,2016 The Apache Software Foundation. All Rights Reserved.