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

Add LIMIT to topic_authors.sparql #1843

Merged
merged 4 commits into from
Feb 16, 2022
Merged

Add LIMIT to topic_authors.sparql #1843

merged 4 commits into from
Feb 16, 2022

Conversation

Daniel-Mietchen
Copy link
Member

Fixes #1842

Description

Please include a summary of the change, relevant motivation and context. If possible and applicable, include before and after screenshots and a URL where the changes can be seen.

Just added a LIMIT to the SPARQL query.

@fnielsen
Copy link
Collaborator

Shouldn't the LIMIT be before the labeling, to avoid spending time on labeling items that are not shown?

@Daniel-Mietchen
Copy link
Member Author

I tested this for a number of the highly curated topics, e.g. schizophrenia. While the LIMIT I chose is 200 (as in many other panels), the number of results we get is sometimes more than that (e.g. 203 right now for Schizophrenia), due to people having multiple ORCIDs. I think this should be fine, but we could make it always 200 by adding LIMIT 200 at the bottom again.

Screenshot from 2022-02-16 14-28-10

#defaultView:Table
SELECT ?count ?author ?authorLabel (COALESCE(?orcid_, CONCAT("orcid-search/quick-search/?searchQuery=", ?authorLabel)) AS ?orcid)
WITH {
SELECT (count(?work) as ?count) ?author WHERE {
SELECT DISTINCT ?author (count(?work) as ?count) WHERE {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is the DISTINCT necessary when we have the GROUP BY?

Add LIMIT to SPARQL query about authors on topic aspect.
Change to use target variable in SPARQL.
Additions: Add description to author in return result and
some minor style changes in the SPARQL
@fnielsen fnielsen merged commit 0db131b into master Feb 16, 2022
@Daniel-Mietchen
Copy link
Member Author

Adding a pointer to

which serves to keep an overview of things we worked on during the hackathon.

@Daniel-Mietchen Daniel-Mietchen deleted the topic-authors-LIMIT-1842 branch February 16, 2022 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

In Topic aspect, add LIMIT to Authors publishing about the topic panel
2 participants