Skip to content

Commit

Permalink
address issue caused by upgrade the arrow-rs
Browse files Browse the repository at this point in the history
  • Loading branch information
liukun4515 committed Jul 28, 2022
1 parent 4ac70a2 commit 8eef9f3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions datafusion/core/tests/parquet_pruning.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
// data into a parquet file and then
use std::sync::Arc;

use arrow::array::DecimalArray;
use arrow::array::Decimal128Array;
use arrow::{
array::{
Array, ArrayRef, Date32Array, Date64Array, Float64Array, Int32Array, StringArray,
Expand Down Expand Up @@ -810,9 +810,9 @@ async fn make_test_file(scenario: Scenario) -> NamedTempFile {
Scenario::Decimal => {
// decimal record batch
vec![
make_decimal_batch(vec![100, 200, 300, 400, 500, 600], 9, 2),
make_decimal_batch(vec![-500, 100, 300, 400, 500, 600], 9, 2),
make_decimal_batch(vec![2000, 3000, 3000, 4000, 5000, 6000], 9, 2),
make_decimal_batch(vec![100, 200, 300, 400, 600], 9, 2),
make_decimal_batch(vec![-500, 100, 300, 400, 600], 9, 2),
make_decimal_batch(vec![2000, 3000, 3000, 4000, 6000], 9, 2),
]
}
};
Expand Down Expand Up @@ -944,7 +944,7 @@ fn make_decimal_batch(v: Vec<i128>, precision: usize, scale: usize) -> RecordBat
true,
)]));
let array = Arc::new(
DecimalArray::from_iter_values(v)
Decimal128Array::from_iter_values(v)
.with_precision_and_scale(precision, scale)
.unwrap(),
) as ArrayRef;
Expand Down

0 comments on commit 8eef9f3

Please sign in to comment.