Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
amosbird committed Jan 22, 2024
1 parent e0e2e35 commit c3bb97d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
0 0 0
10 changes: 10 additions & 0 deletions tests/queries/0_stateless/03000_virtual_columns_in_prewhere.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
drop table if exists x;

create table x (i int, j int, k int) engine MergeTree order by tuple() settings index_granularity=8192, min_bytes_for_wide_part=0, min_rows_for_wide_part=0;

insert into x select number, number * 2, number * 3 from numbers(100000);

-- One granule, (_part_offset (8 bytes) + <one minimal physical column> (4 bytes)) * 8192 + <other two physical columns>(8 bytes) * 1 = 98312
select * from x prewhere _part_offset = 0 settings max_bytes_to_read = 98312;

drop table x;

0 comments on commit c3bb97d

Please sign in to comment.