Hi,
I have a similar issue. I am using result_format="COMPLETE", include_unexpected_rows=True
. Data source is Snowflake. The returned result shows 20 items for violated expectations, but it does not show the failed rows. The total number of violations is 856484, which is returned in the result, but we need all the rows with a violation.
result_format_complete = {"result_format": "COMPLETE", "return_unexpected_index_query":False, "include_unexpected_rows": True}
expectation = gx.expectations.ExpectColumnValuesToNotBeInSet(
column="L_SHIPMODE",
value_set=['RAIL'],
result_format=result_format_complete,
)
result:
{
"success": false,
"expectation_config": {
"type": "expect_column_values_to_not_be_in_set",
"kwargs": {
"result_format": {
"result_format": "COMPLETE",
"return_unexpected_index_query": false,
"include_unexpected_rows": true
},
"batch_id": "inergy-rttpc_lineitem",
"column": "L_SHIPMODE",
"value_set": [
"RAIL"
]
},
"meta": {}
},
"result": {
"element_count": 6001215,
"unexpected_count": 856484,
"unexpected_percent": 14.271843285068107,
"partial_unexpected_list": [
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL",
"RAIL"
],
"missing_count": 0,
"missing_percent": 0.0,
"unexpected_percent_total": 14.271843285068107,
"unexpected_percent_nonmissing": 14.271843285068107,
"partial_unexpected_counts": [
{
"value": "RAIL",
"count": 20
}
]
},
"meta": {},
"exception_info": {
"raised_exception": false,
"exception_traceback": null,
"exception_message": null
}
}