- Introduction to Semantic MediaWiki
- Browsing and searching
- Semantic search
- Selecting pages
- Displaying information
- Result formats
- Inline queries
- Semantic Web
Single page restriction
This section describes how to directly select some pages, or pages from a given namespace.
Giving that the page title is known (possibly including a namespace prefix), as list separated by ||, the Query Engine will match pages with those names. An example is the query
which has three results (at least if the pages exist). Note that the result does not display any namespace prefixes; see the hover box or status bar of the browser, or follow the links to determine the namespace. Restricting the set based on an attribute value one could ask, e.g., «Who of Bill Murray, Dan Aykroyd, Harold Ramis and Ernie Hudson is taller than 6ft?». But direct selection of articles is most useful if further properties of those articles are asked for, e.g. to simply print the height of Bill Murray.
To select a category in this way, a : must be put before the category name. This avoids confusing
[[Category:Actor]] (return all actors) and
[[:Category:Actor]] (return the category «Actor»).
which would return all pages starting with "John" like, e. g. "John Doe", "John Lackland", etc. See <sandbox.semantic-mediawiki.org> for a live example.
- Semantic MediaWiki: GitHub pull request gh:smw:1246