private void insertStringListValuesInBatch(Map<Long, List<String>> stringListIdToValues,
                                             List<Long> stringListIds) throws MetaException {
    List<String> columns = Arrays.asList("\"STRING_LIST_ID\"", "\"INTEGER_IDX\"", "\"STRING_LIST_VALUE\"");
    String insertQuery = TxnUtils.createInsertPreparedStmt("\"SKEWED_STRING_LIST_VALUES\"", columns);
    List<Long> idWithStringList = filterIdsByNonNullValue(stringListIds, stringListIdToValues);
    int maxRows = dbType.getMaxRows(maxBatchSize, 3);
    updateWithStatement(statement -> Batchable.runBatched(maxRows, idWithStringList,
        new Batchable<Long, Void>() {
          @Override
          public List<Void> run(List<Long> input) throws SQLException {
            for (Long stringListId : input) {
              List<String> values = stringListIdToValues.get(stringListId);
              for (int i = 0; i < values.size(); i++) {
                statement.setLong(1, stringListId);
                statement.setInt(2, i);
                statement.setString(3, values.get(i));
                statement.addBatch();
              }
            }
            statement.executeBatch();
            return null;
          }
        }
    ), insertQuery);
  }
Gets the next CS id from sequence MPartitionColumnStatistics and increment the CS id by numStats.
@return The CD id before update.
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/DirectSqlUpdatePart.java