| 3818 | |
| 3819 | #[test] |
| 3820 | fn prune_not_eq_data() { |
| 3821 | let schema = Arc::new(Schema::new(vec![Field::new("s1", DataType::Utf8, true)])); |
| 3822 | |
| 3823 | prune_with_expr( |
| 3824 | // Prune using s2 != 'M' |
| 3825 | col("s1").not_eq(lit("M")), |
| 3826 | &schema, |
| 3827 | &TestStatistics::new().with( |
| 3828 | "s1", |
| 3829 | ContainerStats::new_utf8( |
| 3830 | vec![Some("A"), Some("A"), Some("N"), Some("M"), None, Some("A")], // min |
| 3831 | vec![Some("Z"), Some("L"), Some("Z"), Some("M"), None, None], // max |
| 3832 | ), |
| 3833 | ), |
| 3834 | // s1 [A, Z] ==> might have values that pass predicate |
| 3835 | // s1 [A, L] ==> all rows pass the predicate |
| 3836 | // s1 [N, Z] ==> all rows pass the predicate |
| 3837 | // s1 [M, M] ==> all rows do not pass the predicate |
| 3838 | // No stats for s2 ==> some rows could pass |
| 3839 | // s2 [3, None] (null max) ==> some rows could pass |
| 3840 | &[true, true, true, false, true, true], |
| 3841 | ); |
| 3842 | } |
| 3843 | |
| 3844 | /// Creates setup for boolean chunk pruning |
| 3845 | /// |