<?xml version="1.0" encoding="ISO-8859-1"?>
<!-- $This file is distributed under the terms of the license in LICENSE$ -->

<!-- See guidelines at https://wiki.duraspace.org/x/eYXVAw -->

<list-view-config>
    <query-select>
        PREFIX rdfs: &lt;http://www.w3.org/2000/01/rdf-schema#&gt;
        PREFIX core: &lt;http://vivoweb.org/ontology/core#&gt;
        PREFIX bibo: &lt;http://purl.org/ontology/bibo/&gt;
        PREFIX vitro: &lt;http://vitro.mannlib.cornell.edu/ns/vitro/0.7#&gt;
        PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/&gt;

        SELECT DISTINCT ?subclass
            ?infoResource ?infoResourceName
            ?dateTime
            ?volume
            ?startPage
            ?endPage
            ?locale
        WHERE
        {
            ?subject ?property ?infoResource .
            ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .
            ?infoResource rdfs:label ?infoResourceName .

            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource bibo:volume ?volume .
            }
            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource bibo:pageStart ?startPage .
            }
            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource bibo:pageEnd ?endPage .
            }
            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource core:placeOfPublication ?locale .
            }
            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource vitro:mostSpecificType ?subclass .
            }
            OPTIONAL {
                <precise-subquery>?subject ?property ?infoResource .
                ?infoResource a &lt;http://purl.obolibrary.org/obo/IAO_0000030&gt; .</precise-subquery>
                ?infoResource core:dateTimeValue ?dateTimeValue .
                ?dateTimeValue core:dateTime ?dateTime .
            }

        <critical-data-required>
            FILTER ( bound(?infoResource) )
        </critical-data-required>
        } ORDER BY ?subclass  DESC(?dateTime) ?infoResourceName
    </query-select>

    <template>propStatement-publicationVenueFor.ftl</template>
</list-view-config>
