public static void main(String[] args) throws ClassNotFoundException, SQLException {
    Class.forName("org.apache.iotdb.jdbc.IoTDBDriver");
    try (Connection connection =
            DriverManager.getConnection(
                "jdbc:iotdb://127.0.0.1:6667?version=V_1_0", "root", "root");
        Statement statement = connection.createStatement()) {

      // set JDBC fetchSize
      statement.setFetchSize(10000);

      // create time series

      statement.execute(String.format("CREATE DATABASE %s", DEVICE));
      statement.execute(String.format(CREATE, ROOT_SG1_DIGITS_EXAMPLE));
      statement.execute(String.format(CREATE, ROOT_SG1_KEYWORD_EXAMPLE));
      statement.execute(String.format(CREATE, ROOT_SG1_NORMAL_NODE_EXAMPLE));
      statement.execute(String.format(CREATE, ROOT_SG1_SPECIAL_CHARACTER_EXAMPLE));

      // show timeseries
      ResultSet resultSet = statement.executeQuery("show timeseries root.sg1.*");
      List<String> timeseriesList = new ArrayList<>();
      while (resultSet.next()) {
        timeseriesList.add(resultSet.getString("Timeseries"));
      }
      for (String path : timeseriesList) {
        for (int i = 0; i <= 10; i++) {
          statement.addBatch(prepareInsertStatement(i, path));
        }
      }
      statement.executeBatch();
      statement.clearBatch();

      resultSet = statement.executeQuery("select ** from root.sg1 where time <= 10");
      outputResult(resultSet);
      for (String path : timeseriesList) {
        // For example, for timeseires root.sg1.`111`, sensor is 111, as described in syntax
        // convention, it should be written as `111` in SQL
        // in resultSet of "show timeseries", result is root.sg1.`111`, which means you need not to
        // worry about dealing with backquotes yourself.
        resultSet =
            statement.executeQuery(String.format("select %s from root.sg1", removeDevice(path)));
        outputResult(resultSet);
      }
    } catch (IoTDBSQLException e) {
      e.printStackTrace();
    }
  }
if you want to create a time series named root.sg1.a, a possible SQL statement would be like:
create timeseries root.sg1.a with datatype=FLOAT, encoding=RLE The path should be written as
"root.sg1.a".
example/jdbc/src/main/java/org/apache/iotdb/SyntaxConventionRelatedExample.java