}
void runSQLTest(String stmtName, String stmtSQL) {
// use HSQLDB to get XML that describes the semantics of the statement
// this is much easier to parse than SQL and is checked against the catalog
VoltXMLElement xmlSQL = null;
try {
xmlSQL = m_hsql.getXMLCompiledStatement(stmtSQL);
} catch (HSQLParseException e) {
e.printStackTrace();
assertTrue(false);
}
// output the xml from hsql to disk for debugging
BuildDirectoryUtils.writeFile("statement-hsql-xml", stmtName + ".xml", xmlSQL.toString(), true);
// get a parsed statement from the xml
AbstractParsedStmt parsedStmt = AbstractParsedStmt.parse(stmtSQL, xmlSQL, null, m_db, null);
// analyze expressions
// except for "insert" statements that currently do without a joinTree.