I have a scientific paper collection stored in semantic mediawiki. The page is always the title of the paper. Every paper has a unique id in the form of the citekey property [[Has citekey::someauthor2019]]
.
Now, I want to link it to other publications and automatically show a table of all referenced papers. In order to do that I keep multiple properties per page with a reference property [[Has reference::authorX2017]]
, [[Has reference::authorY2018]]
, etc.
To achieve that I want to get all references with an #ask query and use these results in a new #ask query to get all results that have either of the references as their citekey
property.
To acquire the references I use a combination of this #ask query:
{{#ask: [[Has citekey::someauthor2019]]
|?Has reference
|format=template
|template=Query Result
}}
with this Query Result format Template:
{{{2}}}
For example, this would lead to the output: authorX2017, authorY2018
How can I use this automatically in a new #ask query to obtain a list of the pages that have any of these references as their citekey
property?
Thank you for any advise!