**Describe the situation**

When using parameters (`param`) in the CLI or with the HTTP interface, the EmbeddedRocksDB engine will scan through all the data causing significant slowdown, instead of doing a proper RocksDB key lookup.

**How to reproduce**

setup.sql:
```sql
CREATE TABLE test1 (key String, value String) ENGINE=EmbeddedRocksDB PRIMARY KEY key;

-- do this a few times to exacerbate the issue
INSERT INTO test1 (*) SELECT n.number, randomString(10000) FROM numbers(10000) n;
INSERT INTO test1 (*) SELECT n.number, randomString(10000) FROM numbers(10000) n;
INSERT INTO test1 (*) SELECT n.number, randomString(10000) FROM numbers(10000) n;
```

```
❯ clickhouse client "--param_key=5000" --query "SELECT value FROM test1 WHERE key = {key:String} FORMAT JSON" | jq ".statistics"
{
  "elapsed": 0.20763,
  "rows_read": 10000,
  "bytes_read": 100218890
}

❯ clickhouse client --query "SELECT value FROM test1 WHERE key = '5000' FORMAT JSON" | jq ".statistics"
{
  "elapsed": 0.000519,
  "rows_read": 1,
  "bytes_read": 10022
}
```

**Version**
22.6.1.231


auto primary_key_data_type = sample_block.getByName(primary_key).type;
    std::tie(keys, all_scan) = getFilterKeys(primary_key, primary_key_data_type, query_info);
    if (all_scan)
    {
        auto iterator = std::unique_ptr<rocksdb::Iterator>(rocksdb_ptr->NewIterator(rocksdb::ReadOptions()));
        iterator->SeekToFirst();
        return Pipe(std::make_shared<EmbeddedRocksDBSource>(*this, sample_block, std::move(iterator), max_block_size));
    }
    else
    {
        if (keys->empty())
            return {};
        ::sort(keys->begin(), keys->end());
        keys->erase(std::unique(keys->begin(), keys->end()), keys->end());
        Pipes pipes;
        size_t num_keys = keys->size();
        size_t num_threads = std::min<size_t>(num_streams, keys->size());
        assert(num_keys <= std::numeric_limits<uint32_t>::max());
        assert(num_threads <= std::numeric_limits<uint32_t>::max());
        for (size_t thread_idx = 0; thread_idx < num_threads; ++thread_idx)
        {
            size_t begin = num_keys * thread_idx / num_threads;
            size_t end = num_keys * (thread_idx + 1) / num_threads;
            pipes.emplace_back(std::make_shared<EmbeddedRocksDBSource>(
                    *this, sample_block, keys, keys->begin() + begin, keys->begin() + end, max_block_size));
        }
        return Pipe::unitePipes(std::move(pipes));
    }
}
SinkToStoragePtr StorageEmbeddedRocksDB::write(