Skip to main content

cast_to_composite

Function cast_to_composite 

Source
pub fn cast_to_composite(
    engine: &dyn EngineHook,
    value: &Value,
    source: Option<&ColumnType>,
    target: &ColumnType,
) -> Result<Option<Value>>
Expand description

Cast a value to a composite type: the identity for a value of the same type, record_in for unknown literals and string-category sources, and attribute-wise coercion for anonymous rows and records. Returns None when the target is not a composite type.