cycquery.ops.AndΒΆ

class And(*cond_ops)[source]ΒΆ

Bases: QueryOp

Combine multiple condition query ops using an And.

Parameters:

ops – Query ops to combine.

Examples

>>> And([ConditionLike("lab_name", "HbA1c"), ConditionIn("name", ["John", "Jane"])])
>>> And(ConditionLike("lab_name", "HbA1c"), ConditionIn("name", ["John", "Jane"]))

Methods

__call__(table, return_cond=False)[source]ΒΆ

Process the table.

Parameters:
  • table (Union[Select, Subquery, Table, DBTable]) – Table on which to perform the operation.

  • return_cond (bool) – Return the condition instead of filtering.

Returns:

Processed table.

Return type:

sqlalchemy.sql.selectable.Subquery