`Selected 13 parts by date, 13 parts by key, 26 marks by primary key .... `

This message is confusing for new users.

I suggest to replace it with

`Selected 13 parts by partition key, 13 parts by primary key, 26 marks by primary key...`
size_t next_part = 0;
        for (size_t part_index = 0; part_index < parts.size(); ++part_index)
        {
            auto & part = parts_with_ranges[part_index];
            if (!part.data_part)
                continue;
            sum_ranges += part.ranges.size();
            sum_marks += part.getMarksCount();
            if (next_part != part_index)
                std::swap(parts_with_ranges[next_part], part);
            ++next_part;
        }
        parts_with_ranges.resize(next_part);
    }
    LOG_DEBUG(log, "Selected {} parts by date, {} parts by key, {} marks by primary key, {} marks to read from {} ranges", parts.size(), parts_with_ranges.size(), sum_marks_pk.load(std::memory_order_relaxed), sum_marks, sum_ranges);
    if (parts_with_ranges.empty())
        return {};
    ProfileEvents::increment(ProfileEvents::SelectedParts, parts_with_ranges.size());
    ProfileEvents::increment(ProfileEvents::SelectedRanges, sum_ranges);
    ProfileEvents::increment(ProfileEvents::SelectedMarks, sum_marks);
    Pipe res;
    
    
    
    ExpressionActionsPtr result_projection;
    if (select.final())
    {
        
        std::vector<String> add_columns = metadata_snapshot->getColumnsRequiredForSortingKey();
        column_names_to_read.insert(column_names_to_read.end(), add_columns.begin(), add_columns.end());