"\n\tF10 NVARCHAR2(4)," + //
"\n\tF11 NVARCHAR2(4 BYTE)," + //
"\n\tF12 NVARCHAR2(4 CHAR)" + //
"\n)", SQLUtils.toSQLString(statement, JdbcConstants.ORACLE));
OracleSchemaStatVisitor visitor = new OracleSchemaStatVisitor();
statement.accept(visitor);
System.out.println("Tables : " + visitor.getTables());
System.out.println("fields : " + visitor.getColumns());
System.out.println("coditions : " + visitor.getConditions());
System.out.println("relationships : " + visitor.getRelationships());
System.out.println("orderBy : " + visitor.getOrderByColumns());
Assert.assertEquals(1, visitor.getTables().size());
Assert.assertEquals(12, visitor.getColumns().size());
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F1")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F2")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F3")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F4")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F5")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F6")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F7")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F8")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F9")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F10")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F11")));
Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("T", "F12")));
}