code: public static ResultSet createGeneratedData(long[] data, Protocol protocol,
        boolean findColumnReturnsOne) {
      ColumnInformation[] columns = new ColumnInformation[1];
      columns[0] = ColumnInformation.create("insert_id", ColumnType.BIGINT);
  
      List<byte[]> rows = new ArrayList<>();
      for (long rowData : data) {
        if (rowData != 0) {
          rows.add(StandardPacketInputStream.create(String.valueOf(rowData).getBytes()));
        }
      }
      if (findColumnReturnsOne) {
        return new SelectResultSet(columns, rows, protocol, TYPE_SCROLL_SENSITIVE) {
          @Override
          public int findColumn(String name) {
            return 1;
          }
        };
      }
      return new SelectResultSet(columns, rows, protocol, TYPE_SCROLL_SENSITIVE);
    }
docs: Create a result set from given data. Useful for creating "fake" resultsets for
  DatabaseMetaData, (one example is MariaDbDatabaseMetaData.getTypeInfo())
  
  @param data                 - each element of this array represents a complete row in the
  ResultSet. Each value is given in its string representation, as in
  MariaDB text protocol, except boolean (BIT(1)) values that are
  represented as "1" or "0" strings
  @param protocol             protocol
  @param findColumnReturnsOne - special parameter, used only in generated key result sets
  @return resultset