提交 1903150f 编写于 作者: J Julian Feinauer

Fixed a bug where all tests in IoTDBAggregationIT fail on a System with Locale...

Fixed a bug where all tests in IoTDBAggregationIT fail on a System with Locale different than English.
上级 dd4ecf28
......@@ -35,6 +35,8 @@ import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.util.Locale;
import org.apache.iotdb.db.service.IoTDB;
import org.apache.iotdb.db.utils.EnvironmentUtils;
import org.apache.iotdb.jdbc.Config;
......@@ -579,30 +581,30 @@ public class IoTDBAggregationIT {
statement = connection.createStatement();
// prepare BufferWrite file
for (int i = 5000; i < 7000; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
}
statement.execute("flush");
for (int i = 7500; i < 8500; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
}
statement.execute("flush");
// prepare Unseq-File
for (int i = 500; i < 1500; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
}
statement.execute("flush");
for (int i = 3000; i < 6500; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
}
// statement.execute("merge");
// prepare BufferWrite cache
for (int i = 9000; i < 10000; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "true"));
}
// prepare Overflow cache
for (int i = 2000; i < 2500; i++) {
statement.execute(String.format(insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
statement.execute(String.format(Locale.ENGLISH, insertTemplate, i, i, i, (double) i, "\'" + i + "\'", "false"));
}
statement.close();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册