@@ -168,16 +168,34 @@ void testSQLServerSetStatementIssue1984() throws JSQLParserException {
168
168
String sqlStr = "SET IDENTITY_INSERT tb_inter_d2v_transfer on" ;
169
169
Statements statements = CCJSqlParserUtil .parseStatements (sqlStr ,
170
170
parser -> parser .withUnsupportedStatements (true ));
171
- Assertions . assertEquals (1 , statements .size ());
172
- Assertions . assertInstanceOf (UnsupportedStatement .class , statements .get (0 ));
171
+ assertEquals (1 , statements .size ());
172
+ assertInstanceOf (UnsupportedStatement .class , statements .get (0 ));
173
173
174
174
TestUtils .assertStatementCanBeDeparsedAs (statements .get (0 ), sqlStr , true );
175
175
176
176
Statement statement = CCJSqlParserUtil .parse (sqlStr ,
177
177
parser -> parser .withUnsupportedStatements (true ));
178
- Assertions .assertInstanceOf (UnsupportedStatement .class , statement );
178
+ assertInstanceOf (UnsupportedStatement .class , statement );
179
+
180
+ TestUtils .assertStatementCanBeDeparsedAs (statement , sqlStr , true );
181
+ }
179
182
183
+ @ Test
184
+ void testInformixSetStatementIssue1945 () throws JSQLParserException {
185
+ String sqlStr = "set isolation to dirty read;" ;
186
+ Statement statement = CCJSqlParserUtil .parse (sqlStr ,
187
+ parser -> parser .withUnsupportedStatements (true ));
188
+ assertInstanceOf (UnsupportedStatement .class , statement );
180
189
TestUtils .assertStatementCanBeDeparsedAs (statement , sqlStr , true );
190
+
191
+ TestUtils .assertSqlCanBeParsedAndDeparsed (
192
+ "set isolation to dirty read;" , true , parser -> parser .withUnsupportedStatements ());
181
193
}
182
194
195
+ @ Test
196
+ void testRedshiftSetStatementIssue1708 () throws JSQLParserException {
197
+ Statement st = TestUtils .assertSqlCanBeParsedAndDeparsed (
198
+ "SET x TO y;" , true , parser -> parser .withUnsupportedStatements ());
199
+ assertInstanceOf (UnsupportedStatement .class , st );
200
+ }
183
201
}
0 commit comments