Examples/Different link parameter options

From semantic-mediawiki.org
Jump to: navigation, search
QueriesExamples/Different link parameter options
Description Inline queries offer many different parameters to control printout statements. This help page demonstrates the usage of the different options to the link parameter.
Extension(s) Semantic MediaWiki
Keyword(s) inline queries·table output
Help:Inline queries

Available settings

all (default)

Setting the parameter "link" to "all" means that the results, i.e. the requested pages as well as the requested printouts will be linked. This is the default setting.

{{#ask:
 [[Category:City]]
 [[Located in::+]]
 |?Located in
 |?Population
 |link=all
 |limit=5
}}
 Located inPopulation
AmsterdamNetherlands783,364
BellevilleUnited States of America43,765
BerlinGermany3,520,061
CologneGermany
FrankfurtGermany679,664
... further results

Since this is the default setting one does not explicitly have to state link=all in the query:

{{#ask:
 [[Category:City]]
 [[Located in::+]]
 |?Located in
 |?Population
 |limit=5
}}
 Located inPopulation
AmsterdamNetherlands783,364
BellevilleUnited States of America43,765
BerlinGermany3,520,061
CologneGermany
FrankfurtGermany679,664
... further results

none

Setting the parameter "link" to "none" means that neither the results, i.e. the requested pages nor the requested printouts will be linked.

{{#ask:
 [[Category:City]]
 [[Located in::+]]
 |?Located in
 |?Population
 |link=none
 |limit=5
}}
 Located inPopulation
Demo:AmsterdamNetherlands783,364
BellevilleDemo:United States of America43,765
Demo:BerlinDemo:Germany3,520,061
Demo:CologneDemo:Germany
FrankfurtDemo:Germany679,664
... further results

subject

Setting the parameter "link" to "subject" means that the results, i.e. the requested pages will be linked but not the requested printouts.

{{#ask:
 [[Category:City]]
 [[Located in::+]]
 |?Located in
 |?Population
 |link=subject
 |limit=5
}}
 Located inPopulation
AmsterdamNetherlands783,364
BellevilleDemo:United States of America43,765
BerlinDemo:Germany3,520,061
CologneDemo:Germany
FrankfurtDemo:Germany679,664
... further results