use of com.alibaba.druid.sql.dialect.mysql.ast.statement.MySqlSetTransactionStatement in project druid by alibaba.
the class DALParserTest method testSetTxn_2.
public void testSetTxn_2() throws Exception {
String sql = "SET transaction ISOLATION LEVEL REPEATABLE READ ";
MySqlStatementParser parser = new MySqlStatementParser(sql);
MySqlSetTransactionStatement set = (MySqlSetTransactionStatement) parser.parseStatementList().get(0);
parser.match(Token.EOF);
String output = SQLUtils.toMySqlString(set);
Assert.assertEquals("SET TRANSACTION ISOLATION LEVEL REPEATABLE READ", output);
}
Aggregations