mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
bug fixed for odps sql parser. issue #1495
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
package com.alibaba.druid.bvt.sql.odps;
|
||||
|
||||
import com.alibaba.druid.sql.SQLUtils;
|
||||
import junit.framework.TestCase;
|
||||
|
||||
/**
|
||||
* Created by wenshao on 2016/11/18.
|
||||
*/
|
||||
public class OdpsInsertTest2 extends TestCase {
|
||||
public void test_for_insert_select_limit() throws Exception {
|
||||
String sql = "insert into table a select * from b limit 1";
|
||||
assertEquals("INSERT INTO TABLE a\n" +
|
||||
"SELECT *\n" +
|
||||
"FROM b\n" +
|
||||
"LIMIT 1", SQLUtils.formatOdps(sql));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user