GX Core 1.24: Can a row condition compare the values of two columns?

Question

I am migrating conditional Expectations to GX Core 1.24 and using the new Python-object syntax for row_condition.

My execution engine is Pandas.

The documentation for restricting an Expectation to specific rows explains that a row condition is:

a boolean expression built with Python objects

It shows conditions such as:

from great_expectations.expectations.row_conditions import Column

Column("tenure") > 2
Column("salary") <= 50000
Column("department") == "Sales"

It also lists ==, !=, >, <, >=, and <= as supported comparison operators.

However, all documented examples compare a column with a literal value. The page does not explicitly state whether the value on the right-hand side can be another Column.

What I need to express

I need to apply an Expectation only to rows where the value of one column is greater than the value of another column.

A simplified example is:

from great_expectations.expectations.row_conditions import Column
import great_expectations as gx

expectation = gx.expectations.ExpectColumnValuesToNotBeNull(
    column="end_date",
    row_condition=Column("end_date") > Column("start_date"),
)

Conceptually, the business rule is:

Validate that end_date is not null only for rows where end_date is greater than start_date.

Documentation ambiguity

The ComparisonCondition API reference defines the comparison as:

ComparisonCondition(
    column: Column,
    operator: Operator,
    parameter: Any,
)

The annotation parameter: Any could suggest that another Column might be accepted. However, the description says that the condition represents “the comparison of a column with a parameter,” and there is no column-to-column example.

Questions

  1. Is the following expression officially supported in GX Core 1.24?
Column("end_date") > Column("start_date")

  1. If it is supported, does it work consistently with the Pandas, Spark, and SQL execution engines?

  2. If it is not supported, is this an intentional limitation of the new row_condition API?

  3. What is the recommended GX Core 1.24 approach when a conditional Expectation requires a row-by-row comparison between two columns?

I am aware of column-pair Expectations such as ExpectColumnPairValuesAToBeGreaterThanB. However, that Expectation validates the relationship between the two columns directly. My use case is slightly different: I want the column comparison to select the rows on which another Expectation is evaluated.

I reviewed the row-condition documentation and API reference, but I could not find an explicit statement confirming or excluding column-to-column comparisons.

Thank you.

have you tried just running column end_date > column start_date on a small pandas batch to see what happens? if it errors out cleanly that would at least tell you whether the any parameter accepts another column, even if the docs dont say so.