Functions¶
spark_expectations.utils.udf.get_actions_list(column: Column) -> List[str]
¶
This Spark UDF takes column of type array(map(str,str)) and creates list by picking action_if_failed from dict
Parameters:
Name | Type | Description | Default |
---|---|---|---|
column |
Column
|
Provide a column of type array(map(str,str)) |
required |
Returns:
Name | Type | Description |
---|---|---|
list |
List[str]
|
returns list of action_if_failed from the set expectations rules |
Source code in spark_expectations/utils/udf.py
spark_expectations.utils.udf.remove_empty_maps(column: Column) -> List[Union[Dict[str, str], None]]
¶
This Spark UDF takes a column of type array(map(str,str)) and removes empty maps from it
Parameters:
Name | Type | Description | Default |
---|---|---|---|
column |
Column
|
Provide a column of type array(map(str,str)) |
required |
Returns |
|
required |