21.7.3 throws an exception if `_sample_factor` is used in a query:
```
CREATE TABLE sessions
(
  `user_id` UInt64
)
ENGINE = MergeTree
ORDER BY user_id 
SAMPLE BY user_id;

insert into sessions values(1);

SELECT
    sum(user_id * _sample_factor) 
FROM sessions
SAMPLE 10000000

DB::Exception: Cannot find column `user_id` in source stream (version 21.8.1.7409 (official build))

SELECT
    sum(user_id) 
FROM sessions
SAMPLE 10000000

sum(user_id)
------------
           1
```
No exception on 21.6.5
max_block_numbers_to_read.get(), log, result.index_stats);
    result.sampling = MergeTreeDataSelectExecutor::getSampling(
        select, metadata_snapshot->getColumns().getAllPhysical(), parts, key_condition,
        data, metadata_snapshot, context, sample_factor_column_queried, log);
    if (result.sampling.read_nothing)
        return result;
    size_t total_marks_pk = 0;
    for (const auto & part : parts)
        total_marks_pk += part->index_granularity.getMarksCountWithoutFinal();
    size_t parts_before_pk = parts.size();
    result.parts_with_ranges = MergeTreeDataSelectExecutor::filterPartsByPrimaryKeyAndSkipIndexes(
        std::move(parts),
        metadata_snapshot,
        query_info,
        context,
        key_condition,
        reader_settings,
        log,
        requested_num_streams,
        result.index_stats,
        true ,
        true );
    size_t sum_marks_pk = total_marks_pk;
    for (const auto & stat : result.index_stats)
        if (stat.type == IndexType::PrimaryKey)
            sum_marks_pk = stat.num_granules_after;
    size_t sum_marks = 0;
    size_t sum_ranges = 0;
    size_t sum_rows = 0;
    for (const auto & part : result.parts_with_ranges)