protected static void insertData2() {
    try (Connection iotDBConnection = EnvFactory.getEnv().getConnection(BaseEnv.TABLE_SQL_DIALECT);
        Statement statement = iotDBConnection.createStatement()) {
      statement.execute("use " + DATABASE_NAME);
      statement.execute("create table overflow(device_id STRING TAG, value INT32 FIELD)");
      long startTime = 1;
      for (int i = 0; i < 20; i++) {
        String insertTime =
            "INSERT INTO "
                + "overflow"
                + "(Time,device_id,value) VALUES("
                + (startTime + 2147483648L)
                + ","
                + "'virtual_device'"
                + ","
                + i
                + ")";
        statement.addBatch(insertTime);
        startTime += 2147483648L;
      }
      statement.executeBatch();
      statement.clearBatch();
    } catch (Exception e) {
      e.printStackTrace();
    }
  }
This method generate test data with crossing time.

<p>The data can be viewed in online doc:

<p>https://docs.google.com/spreadsheets/d/18XlOIi27ZIIdRnar2WNXVMxkZwjgwlPZmzJLVpZRpAA/edit#gid=0
integration-test/src/test/java/org/apache/iotdb/relational/it/query/old/alignbydevice/IoTDBOrderByWithAlignByDeviceTableIT.java