@Test public void testCloneSchema() throws ClassNotFoundException, SQLException { final OptiqConnection connection = JdbcTest.getConnection(null, false); Schema foodmart = connection.getRootSchema().getSubSchema("foodmart"); CloneSchema.create(connection.getRootSchema(), "foodmart2", foodmart); Statement statement = connection.createStatement(); ResultSet resultSet = statement.executeQuery( "select count(*) from \"foodmart2\".\"time_by_day\""); assertTrue(resultSet.next()); assertEquals(730, resultSet.getInt(1)); resultSet.close(); connection.close(); }
"foodmart"); if (withClone) { CloneSchema.create( optiqConnection.getRootSchema(), "foodmart2", foodmart);