Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter by null values #757

Closed
fengelniederhammer opened this issue Apr 24, 2024 · 5 comments · Fixed by #760
Closed

Filter by null values #757

fengelniederhammer opened this issue Apr 24, 2024 · 5 comments · Fixed by #760
Assignees
Labels
bug Something isn't working LAPIS Tasks/PR related to LAPIS

Comments

@fengelniederhammer
Copy link
Contributor

It should be possible to filter for null valued fields.

I just checked on the Loculus Ebola instance:

For GET requests it seems to work:

GET /sample/details?accessionVersion=LOC_0001D2F.1&ncbi_is_lab_host= yields a result.
Taken from this swagger request:
grafik

For POST it does not

POST /sample/details
{
  "accessionVersion": "LOC_0001D2F.1",
  "ncbi_is_lab_host": null
}

yields no result.

POST /sample/details
{
  "accessionVersion": "LOC_0001D2F.1"
}

yields the same result as the GET request.

Expected behavior

  • Both GET and POST should return the same results.
  • For both methods it should be possible to filter by null. This should be possible for every sequence filter field that LAPIS offers.
@chaoran-chen
Copy link
Member

Are you sure that it works with GET? I wasn't aware that we ever implemented support for querying null and I assumed that it is currently not possible with SILO.

@fengelniederhammer
Copy link
Contributor Author

SILO supports it:

@chaoran-chen
Copy link
Member

Ah okay, that's super cool! Then, it certainly would be nice to fix the POST request and make it fully work. Priority-wise, after #754?

@fengelniederhammer fengelniederhammer added bug Something isn't working LAPIS Tasks/PR related to LAPIS labels Apr 24, 2024
@JonasKellerer
Copy link
Contributor

Just a reminder from #755: Null can not be entered on boolean columns in GET requests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working LAPIS Tasks/PR related to LAPIS
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants