Skip to content

setConstraints should support constraintLogic and codes #58

@yochannah

Description

@yochannah

An important part of InterMine querying is the ability to set OR logic for constraints, as well as the default AND logic.

This code throws an error, because neither code nor constraintLogic are permissible arguments in setConstraints:

pancreasConstraint2 = setConstraints(
  paths = c("Gene", "Gene.proteinAtlasExpression.level", "Gene.proteinAtlasExpression.level", "Gene.proteinAtlasExpression.tissue.name"),
  operators = c("IN", rep("=", 2), "="),
  values = list("PL_DiabetesGenes", "Medium", "High", "Pancreas"),
  code = c("A", "B", "C", "D"),
  constraintLogic = "A and (B or C) and D"
)

remove the invalid (but needed) code and constraintLogic arguments and it all works fine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions