@prefix this: . @prefix sub: . @prefix schema: . @prefix gen: . @prefix np: . @prefix dct: . @prefix nt: . @prefix npx: . @prefix xsd: . @prefix rdfs: . @prefix prov: . sub:Head { this: a np:Nanopublication; np:hasAssertion sub:assertion; np:hasProvenance sub:provenance; np:hasPublicationInfo sub:pubinfo . } sub:assertion { a gen:Paragraph; schema:about ; schema:title "Multi-value placeholders"; gen:hasContent """

Nanopublication query templates extend grlc syntax by supporting placeholders that can have more than one value. Those have the suffix of \"_multi_iri\" (for IRIs) or just \"_multi\" (for literals). Importantly, they only work if there is at least one occurrence of a \"values\" statement like \"values ?_resource_multi_iri {}\", which indicates where the values are filled in. These multi-value placeholders take 1 or more IRIs/literals.

Every subquery scope needs its own values block. A block in the outer query does not reach into a subquery, and the mistake is silent: the subquery simply matches nothing and the query returns no rows rather than an error.

Starting the name with two underscores instead of one makes a multi-value placeholder optional, as in ?__resource_multi_iri, which accepts zero or more values. With none given, the values block stays empty and the query still runs unconstrained. This is the only placeholder form that can both be tested in the query and be left unfilled.

"""; gen:hasPositionString "01.04" . } sub:provenance { sub:assertion prov:wasAttributedTo . } sub:pubinfo { this: dct:created "2026-09-09T14:46:50Z"^^xsd:dateTime; dct:creator ; dct:license ; npx:introduces ; rdfs:label "Multi-value placeholders"; prov:wasDerivedFrom ; nt:wasCreatedFromProvenanceTemplate ; nt:wasCreatedFromPubinfoTemplate , ; nt:wasCreatedFromTemplate . sub:sig npx:hasAlgorithm "RSA"; npx:hasPublicKey "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAl8cMusqtNyKA6UIsi3f7BAcZmHQXWxU0qk0PLsboMWQxYrGBfGgHTgRHJrBRxL+Zn9kJHKVmz2smDcjCBptXi/OwWy80gjsx+Pbe6IWz3zFPWF1UoFIKfPnC0slV67CQgdM853zW7Bmk9/uflCtK4EtZKmPdRGtUHVC7DTVvDBMDzLRGdE2KCBVN29EbM5GGVNvijYbaZQ9OFQPBkQshayqSIyGRr6rreJdkrRVLIzu3uuAjKYydaeXZWSN2JLnVBwrClKUxaEdCwhb5nXpMtKOMD+R+LgaXLeJUWM8BdRSYnta9ZqI5pHY4y3v+eW7J+HHeTvRbHvlik+Z4hFUXmQIDAQAB"; npx:hasSignature "aL/mdFnZgBQqoy95aT7jgRMZdSgtjQujDd3WTjbmj9r+DLz4hs89cUTnvDbI3aXVtLbRMOe0it2Osv5U9VqWrIkl0DtOyBpi3KSEimhBmqJag+EziCt1VwepoeGBVJvZsJp9U9igOz8gVovK2AFCdC+sQWnOj/PDbKl3rGufg8Re/LTYBlYMr1U3vv5EDMwDsly+FdXRxivNItX3VDiqZAJCGuI/XCEXQ1dGjUU2Gk/Hp5mJZtqf80V5GPxjyas/7ET8umMdLouOHQJBZefhniaVQoJfVY3DUUodd/m59nnHhK2s3YC4DsdWOQ/YFTsXe6Av9XSPH4XzUJLZioDHBQ=="; npx:hasSignatureTarget this:; npx:signedBy . }