# Custom expectations for ExpectColumnPairValuesToBeInSet

**URL:** <https://discourse.greatexpectations.io/t/custom-expectations-for-expectcolumnpairvaluestobeinset/2100>\
**Category:** GX Core Support\
**Tags:** help-wanted\
**Created:** [February 13, 2025, 11:56pm UTC](https://discourse.greatexpectations.io/t/custom-expectations-for-expectcolumnpairvaluestobeinset/2100 "2025-02-13T23:56:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jeyakaran](https://avatars.discourse-cdn.com/v4/letter/j/45deac/32.png) [@Jeyakaran](https://discourse.greatexpectations.io/u/Jeyakaran)\
**Post date:** [February 13, 2025, 11:56pm UTC](https://discourse.greatexpectations.io/t/custom-expectations-for-expectcolumnpairvaluestobeinset/2100/1 "2025-02-13T23:56:54Z")

</div>

Hi,

I am trying to modify the above mentioned expectation for my use case, which needs to check if the values in column\_A and column\_B has the value pairs given in value\_pairs\_set, if yes pass, else fail.

The behaviour of ExpectColumnPairValuesToBeInSet, is such that, if there are any other pairs present in the table, it is considered as fail. So I want to modify it, I am not able to do it! Can someone please help me how can i approach this?

In a simple way, I would like to create a custom column pair map expectation in version 1.3.5, there is no proper docs available as well

---

<div class="post-metadata">

**Author:** ![adeola](https://avatars.discourse-cdn.com/v4/letter/a/b487fb/32.png) [@adeola](https://discourse.greatexpectations.io/u/adeola)\
**Post date:** [March 31, 2025, 6:29pm UTC](https://discourse.greatexpectations.io/t/custom-expectations-for-expectcolumnpairvaluestobeinset/2100/2 "2025-03-31T18:29:44Z")

</div>

we have docs on creating custom expectations [here](https://docs.greatexpectations.io/docs/core/customize_expectations/use_sql_to_define_a_custom_expectation) if this page doesnt help please let me know what step you are finding trouble with
