We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d28d944 commit 73e78c0Copy full SHA for 73e78c0
datafusion/common/src/scalar.rs
@@ -2198,6 +2198,15 @@ impl ScalarValue {
2198
Ok(scalars)
2199
}
2200
2201
+ // TODO: Support more types after other ScalarValue is wrapped with ArrayRef
2202
+ /// Get raw data (inner array) inside ScalarValue
2203
+ pub fn raw_data(&self) -> Result<ArrayRef> {
2204
+ match self {
2205
+ ScalarValue::ListArr(arr) => Ok(arr.to_owned()),
2206
+ _ => _internal_err!("ScalarValue is not a list"),
2207
+ }
2208
2209
+
2210
/// Converts a value in `array` at `index` into a ScalarValue
2211
pub fn try_from_array(array: &dyn Array, index: usize) -> Result<Self> {
2212
// handle NULL value
0 commit comments