Skip to content

Commit

Permalink
Merge 380ba0a into 43f4e16
Browse files Browse the repository at this point in the history
  • Loading branch information
viirya authored Apr 20, 2022
2 parents 43f4e16 + 380ba0a commit bc0cb98
Showing 1 changed file with 28 additions and 5 deletions.
33 changes: 28 additions & 5 deletions parquet/src/arrow/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1018,7 +1018,7 @@ impl ParquetTypeConverter<'_> {
Box::new(Field::new(
key_item.name(),
DataType::Struct(vec![key, value]),
false,
self.schema.is_optional(),
)),
false, // There is no information to tell if keys are sorted
))),
Expand Down Expand Up @@ -1500,7 +1500,7 @@ mod tests {
Field::new("str", DataType::Utf8, false),
Field::new("num", DataType::Int32, false),
]),
false,
true,
)),
false,
),
Expand All @@ -1525,7 +1525,7 @@ mod tests {
Field::new("key", DataType::Utf8, false),
Field::new("value", DataType::Int32, true),
]),
false,
true,
)),
false,
),
Expand Down Expand Up @@ -2096,7 +2096,7 @@ mod tests {
true,
),
]),
false,
true,
)),
false, // fails to roundtrip keys_sorted
),
Expand All @@ -2119,12 +2119,35 @@ mod tests {
true,
),
]),
false,
true,
)),
false, // fails to roundtrip keys_sorted
),
true,
),
Field::new(
"c41",
DataType::Map(
Box::new(Field::new(
"my_entries",
DataType::Struct(vec![
Field::new("my_key", DataType::Utf8, false),
Field::new(
"my_value",
DataType::List(Box::new(Field::new(
"item",
DataType::Utf8,
true,
))),
true,
),
]),
false,
)),
false, // fails to roundtrip keys_sorted
),
false,
),
],
metadata,
);
Expand Down

0 comments on commit bc0cb98

Please sign in to comment.