Skip to content

Commit 7195b37

Browse files
committed
comments
1 parent 4b59786 commit 7195b37

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

datafusion-examples/examples/parquet_index_advanced.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,17 +139,19 @@ async fn main() -> Result<()> {
139139
.show()
140140
.await?;
141141
println!("Files pruned: {}\n", provider.index().last_num_pruned());
142+
// the underlying parquet reader reads ranges from all three files
142143

143144
// Run a query that uses the index to prune files.
144145
//
145146
// Using the predicate "value = 150", the IndexTable can skip reading file 1
146-
// (max value 100) and file 3 (min value of 200)
147+
// (max value 1000) and file 3 (min value of 2000)
147148
println!("** Select data, predicate `value = 1500`");
148149
ctx.sql("SELECT file_name, value FROM index_table WHERE value = 1500")
149150
.await?
150151
.show()
151152
.await?;
152153
println!("Files pruned: {}\n", provider.index().last_num_pruned());
154+
// TODO why are there two calls to read bytes from the file?
153155

154156
// Now, use a predicate on both the value and tag columns. The tag column
155157
// is stored in multiple pages and thus we can prune entire pages based on

0 commit comments

Comments
 (0)