Skip to content
This repository was archived by the owner on Apr 22, 2024. It is now read-only.

Partial matching of strings in generateScientificExpression #680

Closed

Conversation

linupi
Copy link

@linupi linupi commented Jun 10, 2022

Description

This PR adds an additional CONTAINS_STRING condition to the generateScientificExpression function to filter within strings in scientific metadata.

Motivation

When defining our meta data schemas we realized that it would be very helpful for us to also filter on partially matching strings in the scientific metadata. However, so far there is only EQUAL_TO_STRING for text based entries in scientific metadata so we propose an additional CONTAINS_STRING which should work on simple strings as well as on lists. Here is an example:

"scientificMetadata": {
        "localContact": "John Doe",
        "experimentalists": [
                "John Doe",
                "Max Mustermann"
         ]

The idea of the proposed CONTAINS_STRING is that it would match e.g. John in both cases (as localContact as well as in experimentalists)

Changes:

Tests included/Docs Updated?

  • Included for each change/fix?
  • Passing? (Merge will not be approved unless this is checked)
  • Docs updated?
  • New packages used/requires npm install?
  • Toggle added for new features?

@linupi linupi marked this pull request as ready for review June 10, 2022 05:42
Copy link

@henrikjohansson712 henrikjohansson712 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds like a good functionality to have, just make sure to fix the tests before merging.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants