Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "datafusion-functions-json"
version = "0.49.0"
version = "0.49.1"
edition = "2021"
description = "JSON functions for DataFusion"
readme = "README.md"
Expand Down
4 changes: 3 additions & 1 deletion src/common_union.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use std::collections::HashMap;
use std::sync::{Arc, OnceLock};
use std::sync::{Arc, LazyLock, OnceLock};

use datafusion::arrow::array::{
Array, ArrayRef, AsArray, BooleanArray, Float64Array, Int64Array, NullArray, StringArray, UnionArray,
Expand Down Expand Up @@ -48,6 +48,8 @@ pub(crate) fn json_from_union_scalar<'a>(
None
}

pub static JSON_UNION_DATA_TYPE: LazyLock<DataType> = LazyLock::new(JsonUnion::data_type);

#[derive(Debug)]
pub(crate) struct JsonUnion {
bools: Vec<Option<bool>>,
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ mod json_length;
mod json_object_keys;
mod rewrite;

pub use common_union::{JsonUnionEncoder, JsonUnionValue};
pub use common_union::{JsonUnionEncoder, JsonUnionValue, JSON_UNION_DATA_TYPE};

pub mod functions {
pub use crate::json_as_text::json_as_text;
Expand Down
Loading