Difference between revisions of "Module:Wd/doc"
Module:Wd>Gonnym (values update by bot) |
m (1 revision imported) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | {{ | + | <noinclude>{{Documentation subpage}}</noinclude> |
− | {{ | + | {{Hatnote|For the module that should be used in infobox templates instead of this {{lcfirst:{{NAMESPACE}}}}, see [[:Module:WikidataIB]].}} |
− | + | <!-- Original documentation located at [[:en:Template:Wd/doc]]. --> | |
− | + | This {{lcfirst:{{NAMESPACE}}}} is intended to fetch data from '''[[Wikidata]]''' with or without a link to the connected Wikipedia article and with many other features. {{{intro|}}} | |
− | + | ||
− | The | + | == Usage == |
− | + | The general structure of a call to this {{lcfirst:{{NAMESPACE}}}} is as follows. Note that the basic structure consists of positional commands, flags and arguments, which all have a fixed position. | |
− | + | ||
− | + | :{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}{{0| }}{{Background color|#cddae3|<nowiki>|command1|flag1a|flag1b|flag1c</nowiki>}}{{0| }}{{Background color|#dce5ec|<nowiki>|command2|flag2a|flag2b|flag2c</nowiki>}}{{0| }}{{Background color|#c1debf|<nowiki>|flag0a|flag0b|flag0c</nowiki>}}{{0| }}{{Background color|#ffdfc4|<nowiki>|arg1|arg2|arg3</nowiki>}}}} | |
− | + | ||
− | + | Use different [[#Commands|{{Background color|#cddae3|commands}}]] to get different kinds of values from Wikidata. At least one command must be given and multiple commands can be combined into one call as shown above (in any order, more than two is also possible), but this only applies to commands from the [[#Claim class|claim class]]; calls containing a command from the [[#General class|general class]] cannot contain any other command. Each command can be followed by any number of [[#Command flags|{{Background color|#cddae3|command flags}}]], which are optional and can be used to tweak the output generated by that command. | |
− | + | ||
− | + | The commands and their flags may be followed by any number of [[#Configuration flags|{{Background color|#c1debf|configuration flags}}]], which are also optional and affect the selection of data and the {{lcfirst:{{NAMESPACE}}}}'s behaviour in general. The call is closed with the [[#Positional arguments|{{Background color|#ffdfc4|positional arguments}}]], which may be required depending on the given command(s). Some [[#Named arguments|named arguments]] (i.e. name-value pairs) also exist, as well as a set of named flags for [[#Advanced usage|advanced usage]] that can be used to change the way the fetched values are merged together into the output. | |
− | + | ||
− | + | This {{lcfirst:{{NAMESPACE}}}} was designed to provide the basic needs for fetching data from Wikidata, but a lot can be achieved through different combinations of calls. For convenience, such combinations could be wrapped into new templates that serve a specific need. See also the section on [[#Common use cases|common use cases]] below for some examples of useful "building blocks". Likewise, the functionality of this {{lcfirst:{{NAMESPACE}}}} can be extended by creating wrapper templates that use the [[Module:Wd#Main class|<code>main</code> command]] provided by {{module other|this module|[[Module:Wd]] which is being used by this template}} (just like {{t|WikidataOI}} does). | |
− | < | + | |
− | + | === Common use cases === | |
− | + | Below follows a list of common use cases. In the future, shortcut commands may be implemented that are equivalent to these calls for convenience. | |
− | </ | + | {| class="wikitable" |
− | + | |- | |
− | + | ! Call | |
+ | ! Use case | ||
+ | |- | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|label|raw|{{{extraparams|}}}}}}} | ||
+ | | Returns the Q-identifier of the Wikidata item connected to the current page (e.g. "Q55"). | ||
+ | |- | ||
+ | | {{nowrap|<code><nowiki>{{#if:</nowiki>{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|label|raw|{{{extraparams|}}}}}<nowiki>|...}}</nowiki></code>}} | ||
+ | | Performs a check to determine if the current page has a Wikidata item. | ||
+ | Note that this statement relies on a returned value that is either empty or non-empty and that the <code>raw</code> flag is important to include. Without this flag, an existing item's regular label would be returned which could be empty, giving an undesired result. If the flag is given on the other hand, then a non-empty Q-identifier is always returned if an item exists and an empty value if an item does not exist. | ||
+ | |} | ||
+ | |||
+ | == Commands == | ||
+ | The commands (<code>{{Background color|#cddae3|command1}}</code>, <code>{{Background color|#dce5ec|command2}}</code>, ...) determine what kind of values are returned. One call can only contain commands from a single class. | ||
+ | |||
+ | === Claim class === | ||
+ | The claim class commands can be combined, meaning that multiple commands of different types from this class can be given at one time ([[#Usage|see above for usage]]). | ||
+ | |||
+ | Combine multiple commands into one call to this {{lcfirst:{{NAMESPACE}}}}, instead of making multiple calls to this {{lcfirst:{{NAMESPACE}}}} with one command each, to be sure that all the returned pieces of information belong to each other ([[#Examples|see also the examples below]]). | ||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Type | ||
+ | ! Command | ||
+ | ! Returns | ||
+ | ! Basic usage | ||
+ | ! Description | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | I | ||
+ | ! style="text-align:left;" | <code>property</code> | ||
+ | | <small>first match{{efn|Returns only a single value instead of multiple (if multiple claims or statements match). The returned value is the first match found from the best-ranked claims.}}</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|property|P1|{{{extraparams|}}}}}}} | ||
+ | | rowspan="2" | Returns the requested property – or list of properties – from the current item-entity or from a given entity. | ||
+ | This command can be given only once in one call. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>properties</code> | ||
+ | | <small>all matches</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|properties|P1|{{{extraparams|}}}}}}} | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | II | ||
+ | ! style="text-align:left;" | <code>qualifier</code> | ||
+ | | <small>first match{{efn|Returns only a single value instead of multiple for each matching claim. To get at most one value in total in case the <code>property</code> command is not also used, additionally use the [[#Configuration flags|<code>single</code> configuration flag]].|name=fm}}</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|qualifier|P1|P2|{{{extraparams|}}}}}}} | ||
+ | | rowspan="2" | Returns the requested qualifier – or list of qualifiers – from the given property of the current item-entity or of a given entity. | ||
+ | Unlike the other claim class commands, this command can be given multiple times to retrieve different qualifiers in one call. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>qualifiers</code> | ||
+ | | <small>all matches</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|qualifiers|P1|P2|{{{extraparams|}}}}}}} | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | III | ||
+ | ! style="text-align:left;" | <code>reference</code> | ||
+ | | <small>first match{{efn|name=fm}}</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|reference|P1|{{{extraparams|}}}}}}} | ||
+ | | rowspan="2" | Returns a reference – or list of references – from the given property of the current item-entity or of a given entity.{{efn|Only references that are valid according to the [[d:Help:Sources|Wikidata guideline on sources]] are returned (i.e. those that have at least a property {{wpl|P248}} or {{wpl|P854}}).}} | ||
+ | This command can be given only once in one call. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>references</code> | ||
+ | | <small>all matches</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|references|P1|{{{extraparams|}}}}}}} | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | colspan="5" style="text-align:left;" | {{notelist}} | ||
+ | |} | ||
+ | |||
+ | === General class === | ||
+ | The general class commands cannot be combined. | ||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Type | ||
+ | ! Command | ||
+ | ! Returns | ||
+ | ! Basic usage | ||
+ | ! Description | ||
+ | |- | ||
+ | | style="text-align:right;" | I | ||
+ | ! style="text-align:left;" | <code>label</code> | ||
+ | | | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|label|{{{extraparams|}}}}}}} | ||
+ | | Returns the label of the current item-entity or of a given entity if present. | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | style="text-align:right;" | II | ||
+ | ! style="text-align:left;" | <code>title</code> | ||
+ | | | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|title|{{{extraparams|}}}}}}} | ||
+ | | Returns the title of the page connected to the current item-entity or to a given item-entity if such page exists. | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | style="text-align:right;" | III | ||
+ | ! style="text-align:left;" | <code>description</code> | ||
+ | | | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|description|{{{extraparams|}}}}}}} | ||
+ | | Returns the description of the current item-entity or of a given entity if present. | ||
+ | |- | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | IV | ||
+ | ! style="text-align:left;" | <code>alias</code> | ||
+ | | <small>first match{{efn|Returns only a single value instead of multiple (if multiple values are present).|name=fmg}}</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|alias|{{{extraparams|}}}}}}} | ||
+ | | rowspan="2" | Returns an alias – or list of aliases – of the current item-entity or of a given entity if present. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>aliases</code> | ||
+ | | <small>all matches</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|aliases|{{{extraparams|}}}}}}} | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | V | ||
+ | ! style="text-align:left;" | <code>badge</code> | ||
+ | | <small>first match{{efn|name=fmg}}</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|badge|{{{extraparams|}}}}}}} | ||
+ | | rowspan="2" | Returns a badge – or list of badges – for the page connected to the current item-entity or to a given item-entity if such page exists. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>badges</code> | ||
+ | | <small>all matches</small> | ||
+ | | {{nowrap|{{tnull|{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}|badges|{{{extraparams|}}}}}}} | ||
+ | |- | ||
+ | | colspan="5" | | ||
+ | |- | ||
+ | | colspan="5" style="text-align:left;" | {{notelist}} | ||
+ | |} | ||
+ | {{{section|}}} | ||
+ | |||
+ | == Flags == | ||
+ | The following (optional) flags are available which can be used to alter this {{lcfirst:{{NAMESPACE}}}}'s behaviour. They must be given after the (first) {{Background color|#cddae3|command}} and before the {{Background color|#ffdfc4|positional arguments}}. For convenience, empty flags (i.e. <code>||</code>) are allowed and will simply be ignored. | ||
+ | |||
+ | === Command flags === | ||
+ | These flags (<code>{{Background color|#cddae3|flag1*}}</code>, <code>{{Background color|#dce5ec|flag2*}}</code>, ...) apply to the command that precedes them directly. | ||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Flag | ||
+ | ! Description | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>raw</code> | ||
+ | | Returns the raw value if applicable. | ||
+ | |||
+ | If this flag is used with item or property datatypes, then this will return the Q-identifier or P-identifier instead of the regular label. | ||
+ | |||
+ | For quantity datatypes, this flag will strip off any units of measurement, unless the <code>unit</code> flag is also given in which case the raw unit of measurement (its Q-identifier) will be returned. | ||
+ | |||
+ | If this flag is used with time datatypes, then the returned date will be in the format of <code>yyyy-mm-dd</code> (e.g. <code>1731-02-11</code>), or <code>yyyy-mm</code>, or <code>yyyy</code> depending on the date's precision. Dates in the Julian calendar stored with a precision of days through millenniums will have <code>/Julian</code> attached to the output (e.g. <code>1731-02-11/Julian</code>, which may be split off using the [[mw:Help:Extension:ParserFunctions#.23titleparts|<nowiki>{{#titleparts}}</nowiki> parser function]]). | ||
+ | |||
+ | If it is used with globe coordinate datatypes, then it replaces the various symbols with forward slashes in the returned value (e.g. <code>52/5/3/N/4/19/3/E</code>, which may be split into parts using the [[mw:Help:Extension:ParserFunctions#.23titleparts|<nowiki>{{#titleparts}}</nowiki> parser function]]). | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>linked</code> | ||
+ | | Creates a link to the Wikipedia article that is connected to the property or qualifier if it exists. Also links units of measurement that may be appended to values. | ||
+ | |||
+ | If this parameter is omitted, then the plain property or qualifier value will be returned. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>short</code> | ||
+ | | '''<code>{{color|red|[EXPENSIVE]}}</code>''' Returns the {{wpl|P1813}} of any entity returned if they have one attached. If that is not the case, then the default behaviour of returning the entity's label will occur. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>multilanguage</code> | ||
+ | | Returns monolingual text values in any available language, not just the current wiki's language. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>unit</code> | ||
+ | | Returns only the unit of measurement for quantity datatypes. | ||
+ | |} | ||
+ | |||
+ | === Configuration flags === | ||
+ | These flags (<code>{{Background color|#c1debf|flag0*}}</code>) are general configuration flags and can be given anywhere after the first {{Background color|#cddae3|command}} (but before the {{Background color|#ffdfc4|positional arguments}}). | ||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! | ||
+ | ! Flag | ||
+ | ! Description | ||
+ | ! Command class | ||
+ | |- | ||
+ | | rowspan="4" style="text-align:right;" | {{nowrap|Combination of:}} | ||
+ | ! style="text-align:left;" | <code>preferred</code> | ||
+ | | rowspan="4" | Sets a rank constraint for the selected claim(s). | ||
+ | |||
+ | The first three set the ranks for which claim(s) will be selected. They can optionally be followed by a <code>+</code> or a <code>-</code>, e.g. <code>normal+</code> or <code>preferred-</code>, where the first selects claims with a 'normal' rank ''or higher'' and the second selects claims with a 'preferred' rank ''or lower''. To get claims of all ranks, use <code>preferred-</code> or <code>deprecated+</code>. | ||
+ | |||
+ | If the <code>best</code> flag is given additionally, then only the claims that have the highest rank amongst the selected claims will be returned. | ||
+ | |||
+ | The default is <code>normal+|best</code> (so by default claims with a 'deprecated' rank are never returned). | ||
+ | |||
+ | Output is always sorted from highest rank to lowest (regardless of any of these flags being set). | ||
+ | | rowspan="4" | [[#Claim class|claim]] | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>normal</code> | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>deprecated</code> | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>best</code> | ||
+ | |- | ||
+ | | rowspan="3" style="text-align:right;" | {{nowrap|Combination of:}} | ||
+ | ! style="text-align:left;" | <code>future</code> | ||
+ | | rowspan="3" | Sets a time constraint for the selected claim(s). Uses the claims' qualifiers of {{wpl|P580}} and {{wpl|P582}} to determine if the claim is valid for the selected time period(s). | ||
+ | |||
+ | The default is <code>future|current|former</code> (so by default claims that are valid for any time period are returned), except when <code>date=</code> is given ([[#Named arguments|see below]]) in which case the default is <code>current</code>. | ||
+ | | rowspan="3" | claim | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>current</code> | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>former</code> | ||
+ | |- | ||
+ | | | ||
+ | ! style="text-align:left;" | <code>mdy</code> | ||
+ | | Returns date values in month-day-year order instead of day-month-year order. | ||
+ | | claim | ||
+ | |- | ||
+ | | | ||
+ | ! style="text-align:left;" | <code>single</code> | ||
+ | | Returns only a single claim instead of multiple (if multiple claims match). Has no effect if the <code>property</code>/<code>properties</code> command is given, in which case this flag would be redundant. | ||
+ | | claim | ||
+ | |- | ||
+ | | | ||
+ | ! style="text-align:left;" | <code>sourced</code> | ||
+ | | Only returns claims that have at least one valid reference. | ||
+ | | claim | ||
+ | |- | ||
+ | | rowspan="2" style="text-align:right;" | {{nowrap|One of:}} | ||
+ | ! style="text-align:left;" | <code>edit</code> | ||
+ | | rowspan="2" | Adds a clickable icon after the output that may be used by readers to edit the returned claim on Wikidata. | ||
+ | |||
+ | If <code>edit@end</code> is used, then the icon will be placed at the end of the line for neat alignment in infoboxes. | ||
+ | | rowspan="2" | claim, [[#General class|general]] | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>edit@end</code> | ||
+ | |} | ||
+ | |||
+ | == Arguments == | ||
+ | The arguments determine the sources from which all the returned values are fetched. | ||
+ | |||
+ | === Positional arguments === | ||
+ | The following table shows the available positional arguments (<code>{{Background color|#ffdfc4|arg*}}</code>) in their fixed order. For each command, the applicable set of arguments is marked. If multiple commands are given, then the applicable set is the union of the individual sets. For instance, if the commands <code>properties</code> and <code>qualifiers</code> have been given, then at least both the arguments <code>property_id</code> and <code>qualifier_id</code> should be given as well. | ||
+ | |||
+ | More than one <code>qualifier</code>/<code>qualifiers</code> command can be given. The order in which these commands with their flags are given matches the order in which the respective <code>qualifier_id</code> arguments are given. | ||
+ | {| class="wikitable" style="background:none;border:none;" | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" style="background:none;border:none;" | | ||
+ | | colspan="2" | <small>''(required)''</small> | ||
+ | | <small style="color:#777;">''(optional)''</small> | ||
+ | | <small style="color:#777;">(optional)</small> | ||
+ | | <small>(required)</small> | ||
+ | | <small style="color:#777;">(optional)</small> | ||
+ | | <small>(required)</small> | ||
+ | | <small>(required)</small> | ||
+ | | rowspan="2" style="background:none;border:none;" | | ||
+ | |- | ||
+ | | colspan="2" | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | |- | ||
+ | | style="border-right:2px solid #000;" | ''<code><nowiki>{{</nowiki>{{{prename|}}}{{lcfirst:{{ROOTPAGENAME}}}}</code>'' | ||
+ | | colspan="2" style="border-right:2px solid #000;" | ''<code>commands</code>'' | ||
+ | | style="border-right:2px solid #000;" | ''<code style="color:#777;">flags</code>'' | ||
+ | ! style="border-right:2px solid #000;background-color:#ffdfc4;" | <code style="color:#777;">entity_id</code> | ||
+ | ! style="border-right:2px solid #000;background-color:#ffdfc4;" | <code>property_id</code> | ||
+ | ! style="border-right:2px solid #000;background-color:#ffdfc4;" | <code style="color:#777;">raw_value</code> | ||
+ | ! style="border-right:2px solid #000;background-color:#ffdfc4;" | <code>qualifier_id</code> | ||
+ | ! style="background-color:#ffdfc4;" | <code>qualifier_id</code> | ||
+ | | ''<code><nowiki>}}</nowiki></code>'' | ||
+ | |- | ||
+ | | rowspan="12" colspan="2" style="background:none;border:none;" | | ||
+ | | rowspan="2" colspan="2" style="border-style:dashed;border-left-color:blue;border-bottom-color:blue;" | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | rowspan="12" style="background:none;border:none;" | | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" | <code>label</code>, <code>title</code>,<br /><code>description</code>,<br /><code>alias</code>/<code>aliases</code>,<br /><code>badge</code>/<code>badges</code> | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | |- | ||
+ | | rowspan="2" colspan="2" style="border-style:dashed;border-left-color:blue;border-bottom-color:blue;" | | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" colspan="2" style="border-top:none;" | <code>property</code>/<code>properties</code> | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | |- | ||
+ | | rowspan="2" colspan="2" style="border-style:dashed;border-left-color:blue;border-bottom-color:blue;" | | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" colspan="3" style="border-top:none;" | <code>reference</code>/<code>references</code> | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | |- | ||
+ | | rowspan="2" colspan="2" style="border-style:dashed;border-left-color:blue;border-bottom-color:blue;" | | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" colspan="4" style="border-top:none;" | <code>qualifier</code>/<code>qualifiers</code> | ||
+ | | rowspan="2" style="border-top:none;border-bottom:none;" | | ||
+ | |- | ||
+ | | rowspan="2" colspan="2" style="border-style:dashed;border-left-color:blue;border-bottom-color:blue;" | | ||
+ | |- style="text-align:center;" | ||
+ | | rowspan="2" colspan="5" style="border-top:none;" | <code>qualifier</code>/<code>qualifiers</code> ''(optional 2<sup>nd</sup>, 3<sup>rd</sup>, etc.)'' | ||
+ | |- | ||
+ | | rowspan="2" colspan="2" style="border:none;" | | ||
+ | |- | ||
+ | | colspan="5" style="border:none;" | | ||
+ | |} | ||
+ | |||
+ | Below follows a description of all positional arguments. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Argument | ||
+ | ! Description | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code style="color:#777;">entity_id</code> | ||
+ | |||
+ | <small style="font-weight:normal;">(optional)</small> | ||
+ | | '''<code>{{color|red|[EXPENSIVE]}}</code>''' '''Q-identifier''' of the item-entity to be accessed (e.g. <code>Q55</code>), '''P-identifier''' (or an available '''[[#Property aliases|alias]]''') of the property-entity to be accessed preceded by the <code>Property:</code> prefix (e.g. <code>Property:P38</code>), or '''page title''' of the Wikipedia article whose connected item-entity is to be accessed preceded by <code>:</code>, a prefixed colon (e.g. <code>:Netherlands</code>). | ||
+ | |||
+ | In case of the [[#General class|general class commands]], the <code>Property:</code> prefix may be omitted for P-identifiers (e.g. <code>P38</code>). | ||
+ | |||
+ | If this parameter is omitted, then the item-entity connected to the current page will be used (except when <code>eid=</code> or <code>page=</code> is given, [[#Named arguments|see below]]). If this parameter is given, but empty (i.e. <code>||</code>), then due to its position it will be interpreted as an [[#Flags|empty flag]] and thus be ignored, giving the same result as if it were omitted. See also the [[#Named arguments|named arguments <code>eid=</code> and <code>page=</code>]] below that can be used to give an entity-ID or page title too, but without the item-entity connected to the current page being used as a default. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>property_id</code> | ||
+ | | '''P-identifier''' (or an available '''[[#Property aliases|alias]]''') of the property within the entity to be accessed, without the <code>Property:</code> prefix (e.g. <code>P35</code>). | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code style="color:#777;">raw_value</code> | ||
+ | |||
+ | <small style="font-weight:normal;">(optional)</small> | ||
+ | | Either the '''Q-identifier''' equal to the property value (e.g. <code>Q29574</code>) or a '''literal value''' (i.e. string or quantity etc., ''no entity label'') equal to the raw property value of the particular claim to be accessed. | ||
+ | |||
+ | Dates as literal values must be formatted <code>yyyy-mm-dd</code> (e.g. <code>1731-02-11</code>) for dates with a precision of days, <code>yyyy-mm</code> (e.g. <code>1731-02</code>) for dates with a precision of months, and <code>yyyy</code> (e.g. <code>1731</code>) for dates of lesser precision. Dates BCE require a minus sign in front of the year (e.g. <code>-2950-01-31</code>). Dates stored in the Julian calendar must have <code>/Julian</code> attached to the end (e.g. <code>1731-02-11/Julian</code>). Decades like the 2010s must be given as <code>2010</code> (but the 2010s BCE as <code>-2019</code>), centuries like the 20th century as <code>1901</code> (but the 20th century BCE as <code>-2000</code>), and millenniums like the 3rd millennium as <code>2001</code> (but the 3rd millennium BCE as <code>-3000</code>). | ||
+ | |||
+ | Globe coordinates as literal values must be formatted with forward slashes (i.e. <code>/</code>) between the parts and no symbols (e.g. <code>52/5/3/N/4/19/3/E</code>) ''without any spaces or leading zeros''. | ||
+ | |||
+ | The special type ''''no value'''' can be given by entering the empty string (i.e. <code>||</code>) and the special type ''''unknown value'''' can be given by entering a single underscore (i.e. <code>|_|</code>). To get a literal underscore, escape it by placing a backslash <code>\</code> directly in front of it (i.e. <code>\_</code>); the same holds for a literal backslash (i.e. <code>\\</code>). | ||
+ | |||
+ | To get a literal vertical bar <code>|</code>, use <code>{{tl|!}}</code> or <code>&#124;</code>. | ||
+ | |||
+ | If this parameter is omitted, then all claims (matching any other constraints) within the property will be accessed. | ||
+ | |- | ||
+ | ! style="text-align:left;" | <code>qualifier_id</code> | ||
+ | | '''P-identifier''' (or an available '''[[#Property aliases|alias]]''') of the qualifier within the entity to be accessed, without the <code>Property:</code> prefix (e.g. <code>P580</code>). | ||
+ | |} | ||
+ | |||
+ | === Named arguments === | ||
+ | Below follows a description of all named arguments, which are name-value pairs (i.e. <code>|name=value</code>). These are all optional and can be given anywhere {{module other|after the first command|inside the call}}. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Argument | ||
+ | ! Description | ||
+ | ! Command class | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>eid=</code> | ||
+ | | '''<code>{{color|red|[EXPENSIVE]}}</code>''' This argument can be used to give the '''Q-identifier''' (e.g. <code>|eid=Q55</code>) or '''P-identifier''' (or an available '''[[#Property aliases|alias]]''') of the entity to be accessed. It offers the same functionality as the [[#Positional arguments|positional argument <code>entity_id</code>]], with one difference: if the argument is given but its value is left empty (i.e. <code>|eid=</code>), then no entity is accessed at all instead of the item-entity connected to the current page. This is useful in some cases where a variable entity-ID is expected, but where the item-entity connected to the current page should not be accessed as the default. | ||
+ | |||
+ | Also, the <code>Property:</code> prefix may be omitted for P-identifiers (e.g. <code>|eid=P38</code>) for all commands. | ||
+ | |||
+ | This argument only has effect if the positional argument <code>entity_id</code> is omitted. | ||
+ | | [[#Claim class|claim]], [[#General class|general]] | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>page=</code> | ||
+ | | '''<code>{{color|red|[EXPENSIVE]}}</code>''' This argument can be used to give the '''page title''' (e.g. <code>|page=Netherlands</code>) of the Wikipedia article whose connected item-entity is to be accessed. It behaves similar to the named argument <code>eid=</code> and can be used instead of the [[#Positional arguments|positional argument <code>entity_id</code>]] (note that no prefixed colon, <code>:</code>, is required). If the argument is given but its value is left empty (i.e. <code>|page=</code>), then no entity is accessed at all instead of the item-entity connected to the current page. | ||
+ | |||
+ | This argument only has effect if the positional argument <code>entity_id</code> and the named argument <code>eid=</code> are omitted. | ||
+ | | claim, general | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>date=</code> | ||
+ | | This argument can be used to set a particular date (e.g. <code>|date=1731-02-11</code>) relative to which claim matching using the [[#Configuration flags|<code>future</code>, <code>current</code> and <code>former</code> flags]] is done, instead of relative to today. It overrides the default of these flags to <code>current</code> so that by default only claims that were valid at the given date are returned (based on the claims' qualifiers of {{wpl|P580}} and {{wpl|P582}}). | ||
+ | |||
+ | The date value must be formatted <code>yyyy-mm-dd</code> (e.g. <code>1731-02-11</code>), <code>yyyy-mm</code> (e.g. <code>1731-02</code>) or <code>yyyy</code> (e.g. <code>1731</code>). | ||
+ | | claim | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>''<qualifier>''=</code> | ||
+ | | The <code>''<qualifier>''</code> is a placeholder for a set of arguments that determine which claims should be accessed based on qualifier value, analogous to the pair of [[#Positional arguments|positional arguments <code>property_id</code> and <code>raw_value</code>]] (that determine access based on property value). | ||
+ | |||
+ | As such, <code>''<qualifier>''</code> is any qualifier's '''P-identifier''' (or an available '''[[#Property aliases|alias]]''') without the <code>Property:</code> prefix (e.g. <code>P518</code>). Its value is either the '''Q-identifier''' equal to one of the qualifier values (e.g. <code>Q27561</code>) or a '''literal value''' (i.e. string or quantity etc., ''no entity label'') equal to one of the raw qualifier values of the particular claim to be accessed. The value format is the same as for the positional argument <code>raw_value</code>. The special type ''''no value'''' given by the empty string also matches the total absence within the claim of the particular qualifier. | ||
+ | |||
+ | Example: <code>|P518=Q27561</code> | ||
+ | |||
+ | Multiple arguments of this type can be given to match multiple qualifier values simultaneously for each claim. | ||
+ | | claim | ||
+ | |} | ||
+ | |||
+ | === Property aliases === | ||
+ | Property aliases are other names for P-identifiers that can be used instead. The following property aliases (which are [[Case sensitivity|case-sensitive]]) are currently available: | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Alias | ||
+ | ! <sub>translates<br /></sub><sup>to</sup> | ||
+ | ! P-identifier | ||
+ | |- <!-- property aliases purely for convenience --> | ||
+ | | coord ||style="text-align: center;"| → || [[d:Property:P625|P625]] | ||
+ | |- | ||
+ | !colspan="3"| | ||
+ | |- <!-- property aliases used by the module itself --> | ||
+ | | image ||style="text-align: center;"| → || [[d:Property:P18|P18]] | ||
+ | |- | ||
+ | | author ||style="text-align: center;"| → || [[d:Property:P50|P50]] | ||
+ | |- | ||
+ | | publisher ||style="text-align: center;"| → || [[d:Property:P123|P123]] | ||
+ | |- | ||
+ | | importedFrom ||style="text-align: center;"| → || [[d:Property:P143|P143]] | ||
+ | |- | ||
+ | | statedIn ||style="text-align: center;"| → || [[d:Property:P248|P248]] | ||
+ | |- | ||
+ | | pages ||style="text-align: center;"| → || [[d:Property:P304|P304]] | ||
+ | |- | ||
+ | | language ||style="text-align: center;"| → || [[d:Property:P407|P407]] | ||
+ | |- | ||
+ | | hasPart ||style="text-align: center;"| → || [[d:Property:P527|P527]] | ||
+ | |- | ||
+ | | publicationDate ||style="text-align: center;"| → || [[d:Property:P577|P577]] | ||
+ | |- | ||
+ | | startTime ||style="text-align: center;"| → || [[d:Property:P580|P580]] | ||
+ | |- | ||
+ | | endTime ||style="text-align: center;"| → || [[d:Property:P582|P582]] | ||
+ | |- | ||
+ | | chapter ||style="text-align: center;"| → || [[d:Property:P792|P792]] | ||
+ | |- | ||
+ | | retrieved ||style="text-align: center;"| → || [[d:Property:P813|P813]] | ||
+ | |- | ||
+ | | referenceURL ||style="text-align: center;"| → || [[d:Property:P854|P854]] | ||
+ | |- | ||
+ | | sectionVerseOrParagraph ||style="text-align: center;"| → || [[d:Property:P958|P958]] | ||
+ | |- | ||
+ | | archiveURL ||style="text-align: center;"| → || [[d:Property:P1065|P1065]] | ||
+ | |- | ||
+ | | title ||style="text-align: center;"| → || [[d:Property:P1476|P1476]] | ||
+ | |- | ||
+ | | formatterURL ||style="text-align: center;"| → || [[d:Property:P1630|P1630]] | ||
+ | |- | ||
+ | | quote ||style="text-align: center;"| → || [[d:Property:P1683|P1683]] | ||
+ | |- | ||
+ | | shortName ||style="text-align: center;"| → || [[d:Property:P1813|P1813]] | ||
+ | |- | ||
+ | | definingFormula ||style="text-align: center;"| → || [[d:Property:P2534|P2534]] | ||
+ | |- | ||
+ | | archiveDate ||style="text-align: center;"| → || [[d:Property:P2960|P2960]] | ||
+ | |- | ||
+ | | inferredFrom ||style="text-align: center;"| → || [[d:Property:P3452|P3452]] | ||
+ | |- | ||
+ | | typeOfReference ||style="text-align: center;"| → || [[d:Property:P3865|P3865]] | ||
+ | |- | ||
+ | | column ||style="text-align: center;"| → || [[d:Property:P3903|P3903]] | ||
+ | |} | ||
+ | |||
+ | == Advanced usage == | ||
+ | The layout of the output from (a combination of) commands that have both a singular and a plural form (e.g. <code>property</code>/<code>properties</code>) can be customized by using a number of named flags, which are name-value pairs (i.e. <code>|flag=value</code>), that can be given anywhere {{module other|after the first command|inside the call}}. The table below shows the available named flags. | ||
+ | |||
+ | To insert a space at the beginning or end of a <code>value</code>, use an underscore <code>_</code>. To get a literal underscore, escape it by placing a backslash <code>\</code> directly in front of it (i.e. <code>\_</code>); the same holds for a literal backslash (i.e. <code>\\</code>). To get a literal vertical bar <code>|</code>, use <code>{{tl|!}}</code> or <code>&#124;</code>. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Named flag | ||
+ | ! Default value | ||
+ | ! Default condition | ||
+ | ! Description | ||
+ | |- | ||
+ | ! rowspan="6" style="text-align:right;" | <code>format=</code> | ||
+ | | <code>%p[%s][%r]</code> | ||
+ | | if the <code>property</code>/<code>properties</code> command '''was''' given and the <code>qualifier</code>/<code>qualifiers</code> command '''was not''' given | ||
+ | | rowspan="6" | The format of a single claim. The available parameters are as follows. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Parameter | ||
+ | ! Description | ||
+ | |- | ||
+ | | <code>%p</code> | ||
+ | | The claim's property value applied by the <code>property</code>/<code>properties</code> command. | ||
+ | |- | ||
+ | | <code>%q1</code>, <code>%q2</code>, <code>%q3</code>, ... | ||
+ | | The claim's qualifier value or list of qualifier values applied by the corresponding <code>qualifier</code>/<code>qualifiers</code> command. | ||
+ | |- | ||
+ | | <code>%q</code> | ||
+ | | The collection of the qualifier values applied by each <code>qualifier</code>/<code>qualifiers</code> command (i.e. <code>%q1</code> + <code>%q2</code> + <code>%q3</code> + ...). If only one <code>qualifier</code>/<code>qualifiers</code> command was given, then this parameter is equivalent to <code>%q1</code>. | ||
+ | |- | ||
+ | | <code>%r</code> | ||
+ | | The claim's reference value or list of reference values applied by the <code>reference</code>/<code>references</code> command. | ||
+ | |- | ||
+ | | <code>%a</code> | ||
+ | | The entity's alias applied by the <code>alias</code>/<code>aliases</code> command. | ||
+ | |- | ||
+ | | <code>%b</code> | ||
+ | | The entity's page badge applied by the <code>badge</code>/<code>badges</code> command. | ||
+ | |- | ||
+ | | <code>%s</code> | ||
+ | | The movable separator placeholder. This is a special parameter that is not applied by a command, but instead is filled automatically between each pair of claims, aliases or badges (if a list of claims, aliases or badges is returned). This is particularly handy in case a claim's reference is returned as well, since it allows the reference to be placed after the punctuation mark as prescribed by [[Wikipedia:Manual of Style#Punctuation and footnotes|Wikipedia's manual of style]]. The default value is a comma (<code>,</code>) and can be overridden with the <code>sep%s</code> flag (see below). | ||
+ | |} | ||
+ | |||
+ | Optional parameters can be given by encapsulating them between square brackets: <code>[...]</code>. All content between the square brackets is only displayed if a value for each optional parameter that has been defined between the same brackets has been found. Optional content can also be nested. | ||
+ | |||
+ | To use two opening square brackets that directly follow each other (i.e. <code>{{!((}}</code>), use <code>{{tl|!((}}</code>. | ||
+ | |||
+ | At least one parameter must be given that is not optional, while the <code>%s</code> parameter must always be defined as optional. | ||
+ | |||
+ | To get a literal <code>[</code>, <code>]</code>, <code>%</code> or <code>\</code>, escape the character by placing a backslash <code>\</code> directly in front of it (e.g. <code>\%</code>). See also the description directly above this table for more. | ||
+ | |- | ||
+ | | <code>%q[%s][%r]</code> | ||
+ | | if the <code>property</code>/<code>properties</code> command '''was not''' given and the <code>qualifier</code>/<code>qualifiers</code> command '''was''' given | ||
+ | |- | ||
+ | | <code>%r</code> | ||
+ | | if '''only''' the <code>reference</code>/<code>references</code> command was given | ||
+ | |- | ||
+ | | <code><nowiki>%p[ <span style="font-size:85\%">(%q)</span>][%s][%r]</nowiki></code> | ||
+ | | if the <code>property</code>/<code>properties</code> command '''was''' given and the <code>qualifier</code>/<code>qualifiers</code> command '''was''' given | ||
+ | |- | ||
+ | | <code>%a[%s]</code> | ||
+ | | if the <code>alias</code>/<code>aliases</code> command was given | ||
+ | |- | ||
+ | | <code>%b[%s]</code> | ||
+ | | if the <code>badge</code>/<code>badges</code> command was given | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! rowspan="2" style="text-align:right;" | <code>sep=</code> | ||
+ | | <code>{{dfn|_|title=space}}</code> | ||
+ | | <span style="color:#777;">''default''</span> | ||
+ | | rowspan="2" | The fixed separator between each pair of claims, aliases or badges. | ||
+ | |- | ||
+ | | {{dfn|<code>{{0| }}</code>|title=empty}} | ||
+ | | if '''only''' the <code>reference</code>/<code>references</code> command was given '''without''' the <code>raw</code> flag | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! rowspan="2" style="text-align:right;" | <code>sep%s=</code> | ||
+ | | <code>,</code> | ||
+ | | <span style="color:#777;">''default''</span> | ||
+ | | rowspan="2" | The movable separator between each pair of claims, aliases or badges. This will be the value of the <code>%s</code> parameter applied to all claims, aliases or badges, except for the last in the list (which can be set with the <code>punc</code> flag). | ||
+ | |- | ||
+ | | <code>;</code> | ||
+ | | if the <code>property</code>/<code>properties</code> command '''was not''' given and the <code>qualifier</code>/<code>qualifiers</code> command '''was''' given | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>sep%q1=</code>, <code>sep%q2=</code>, <code>sep%q3=</code>, ... | ||
+ | | <code>{{dfn|,_|title=comma space}}</code> | ||
+ | | <span style="color:#777;">''default''</span> | ||
+ | | The separator between each pair of qualifiers of a single claim. These are the value separators for the <code>%q1</code>, <code>%q2</code>, <code>%q3</code>, ... parameters. | ||
+ | If only one <code>qualifier</code>/<code>qualifiers</code> command was given, then the <code>sep%q1</code> flag is equivalent to <code>sep%q</code>. | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! rowspan="2" style="text-align:right;" | <code>sep%q=</code> | ||
+ | | <code>{{dfn|,_|title=comma space}}</code> | ||
+ | | if '''exactly one''' <code>qualifier</code>/<code>qualifiers</code> command was given | ||
+ | | rowspan="2" | The separator between each set of qualifiers of a single claim. This is the value separator for the <code>%q</code> parameter. | ||
+ | If only one <code>qualifier</code>/<code>qualifiers</code> command was given, then this flag is equivalent to <code>sep%q1</code>. | ||
+ | |- | ||
+ | | <code>{{dfn|{{;}}_|title=semicolon space}}</code> | ||
+ | | if '''more than one''' <code>qualifier</code>/<code>qualifiers</code> command was given | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! rowspan="2" style="text-align:right;" | <code>sep%r=</code> | ||
+ | | {{dfn|<code>{{0| }}</code>|title=empty}} | ||
+ | | <span style="color:#777;">''default''</span> | ||
+ | | rowspan="2" | The separator between each pair of references of a single claim. This is the value separator for the <code>%r</code> parameter. | ||
+ | |- | ||
+ | | <code>{{dfn|_|title=space}}</code> | ||
+ | | if the <code>raw</code> flag '''was''' given for the <code>reference</code>/<code>references</code> command | ||
+ | |- | ||
+ | | colspan="4" | | ||
+ | |- | ||
+ | ! style="text-align:right;" | <code>punc=</code> | ||
+ | | {{dfn|<code>{{0| }}</code>|title=empty}} | ||
+ | | <span style="color:#777;">''default''</span> | ||
+ | | A punctuation mark placed at the end of the output. This will be placed on the <code>%s</code> parameter applied to the last claim (or alias or badge) in the list. | ||
+ | This allows the last claim's references to be placed after the punctuation mark when the output is used as part of a sentence. | ||
+ | |} | ||
+ | |||
+ | == Examples == | ||
+ | <!-- | ||
+ | TO UPDATE EXAMPLE RESULTS at [[Template:Wd/doc]], replace all the contents of the 'Examples' section with: {{subst:Template:Wd/doc/examples}} | ||
+ | (This makes the example results static for performance reasons.) | ||
+ | |||
+ | Changes to examples and additions of new examples should be made at [[Template:Wd/doc/examples]] after which the contents of the 'Examples' section at [[Template:Wd/doc]] should be substituted as described above. | ||
+ | |||
+ | The examples section is a bit bloated, though... For a bit of convenience, the following table row can be used as a basic template for any new example (note the 'xxx' that need to be replaced): | ||
+ | |||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Pxxx = "{{{{{|safesubst:}}}#invoke:wd|label|Pxxx}}"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|xxx}}] | ||
+ | | {{tnull|{{{{{|safesubst:}}}(((}}prename|{{{{{|safesubst:}}})))}}{{lcfirst:{{BASEPAGENAME}}}}|property|Pxxx|{{{{{|safesubst:}}}(((}}extraparams|{{{{{|safesubst:}}})))}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :{{{{{|safesubst:}}}#invoke:wd|property|Pxxx}} | ||
+ | | Description... | ||
+ | |||
+ | --> | ||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Parameters and output types | ||
+ | ! Example | ||
+ | ! style="width:20%"|Description | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q55|Q55]] = "Netherlands", [[d:Property:P395|P395]] = "licence plate code"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q55|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL | ||
+ | | Gets a literal string value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | P395 = "licence plate code"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Netherlands]] page (which is linked to Q55), then the <code>Q55</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P395 = "NL"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''eid{{=}}Q55'''|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL | ||
+ | | An entity-ID can also be given using the <code>eid=</code> argument. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | P395 = "NL"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''page{{=}}Netherlands'''|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL | ||
+ | | A page title can be given instead of an entity-ID using the <code>page=</code> argument. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P395 = "licence plate code"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''edit'''|Q55|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL [[File:OOjs UI icon edit-ltr-progressive.svg|frameless|text-top|10px|alt=Edit this on Wikidata|link=https://www.wikidata.org/wiki/Q55?uselang=en#P395|Edit this on Wikidata]] | ||
+ | | Adds a clickable icon that may be used to edit the returned value on Wikidata. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P395 = "licence plate code"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|string}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''edit@end'''|Q55|P395|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :NL<span style="float:right">[[File:OOjs UI icon edit-ltr-progressive.svg|frameless|text-top|10px|alt=Edit this on Wikidata|link=https://www.wikidata.org/wiki/Q55?uselang=en#P395|Edit this on Wikidata]]</span> | ||
+ | | Places the edit icon at the end of the line. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P1082|P1082]] = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''property'''|'''normal+'''|Q55|P1082|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :17,282,163 | ||
+ | | Gets a single property value from claims with a 'normal' rank or higher. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''properties'''|normal+|Q55|P1082|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :17,282,163, 16,829,289, 16,779,575, 10,026,773, 17,000,000, 17,132,854, 17,181,084 | ||
+ | | Gets multiple property values from claims with a 'normal' rank or higher. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", [[d:Property:P585|P585]] = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''qualifier'''|normal+|Q55|P1082|'''P585'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :17,282,163 <span style="font-size:85%">(2019)</span>, 16,829,289 <span style="font-size:85%">(26 August 2014)</span>, 16,779,575 <span style="font-size:85%">(2013)</span>, 10,026,773 <span style="font-size:85%">(1950)</span>, 17,000,000 <span style="font-size:85%">(21 March 2016)</span>, 17,132,854 <span style="font-size:85%">(2017)</span>, 17,181,084 <span style="font-size:85%">(1 January 2018)</span> | ||
+ | | Gets a single qualifier value for each claim, additional to the property value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|time}}], [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|'''references'''|normal+|Q55|P1082|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :17,282,163 <span style="font-size:85%">(2019)</span>,<ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref> 16,829,289 <span style="font-size:85%">(26 August 2014)</span>,<ref name="wikidata-cea8d68b073c3e015eb19fca29cfdd632fc42c65-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&LA=NL; retrieved: 26 August 2014.</ref> 16,779,575 <span style="font-size:85%">(2013)</span>,<ref name="wikidata-a320e0a81aa82b19d4b7f1b9e71f39c153da28ab-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&D1=a&D2=0,10,20,30,40,50,60,(l-1),l&HD=130605-0924&HDR=G1&STB=T; retrieved: 22 August 2015; publisher: Statistics Netherlands.</ref> 10,026,773 <span style="font-size:85%">(1950)</span>,<ref name="wikidata-a320e0a81aa82b19d4b7f1b9e71f39c153da28ab-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&D1=a&D2=0,10,20,30,40,50,60,(l-1),l&HD=130605-0924&HDR=G1&STB=T; retrieved: 22 August 2015; publisher: Statistics Netherlands.</ref> 17,000,000 <span style="font-size:85%">(21 March 2016)</span>,<ref name="wikidata-928a3addb389f1dc02548a71c7d09a2a7f8ba2f9-v3">http://www.cbs.nl/nl-NL/menu/themas/bevolking/publicaties/artikelen/archief/2016/nederland-telt-17-miljoen-inwoners.htm.</ref> 17,132,854 <span style="font-size:85%">(2017)</span>,<ref name="wikidata-b9afa65b0872528113472db065673a53e65e8a2f-v3">https://data.worldbank.org/indicator/SP.POP.TOTL; ''World Bank Open Data''; retrieved: 8 April 2019.</ref> 17,181,084 <span style="font-size:85%">(1 January 2018)</span><ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref> | ||
+ | | Gets references for each claim. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|reference}}] | ||
+ | | <code>A total of {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|references|Q55|P1082|{{{extraparams|}}}}} people live in the Netherlands.</code><br /> | ||
+ | :↓<br /> | ||
+ | :A total of 17,282,163<ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref> people live in the Netherlands. | ||
+ | | Gets a property with its references. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|reference}}] | ||
+ | | <code>The Netherlands has a population of {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|references|Q55|P1082|'''punc{{=}}.'''|{{{extraparams|}}}}}</code> | ||
+ | :↓<br /> | ||
+ | :The Netherlands has a population of 17,282,163.<ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref> | ||
+ | | Adds a punctuation mark at the end of the output, in front of the references. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|time}}], [{{smallcaps|reference}}] | ||
+ | | <code>'''<nowiki><ul></nowiki>'''{{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|references|normal+|Q55|P1082|P585|'''<nowiki>format=<li>%p[%r][<ul><li>%q</li></ul>]</li></nowiki>'''|{{{extraparams|}}}}}'''<nowiki></ul></nowiki>'''</code><br /> | ||
+ | :↓<br /> | ||
+ | <ul><li>17,282,163<ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref><ul><li>2019</li></ul></li> <li>16,829,289<ref name="wikidata-cea8d68b073c3e015eb19fca29cfdd632fc42c65-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&LA=NL; retrieved: 26 August 2014.</ref><ul><li>26 August 2014</li></ul></li> <li>16,779,575<ref name="wikidata-a320e0a81aa82b19d4b7f1b9e71f39c153da28ab-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&D1=a&D2=0,10,20,30,40,50,60,(l-1),l&HD=130605-0924&HDR=G1&STB=T; retrieved: 22 August 2015; publisher: Statistics Netherlands.</ref><ul><li>2013</li></ul></li> <li>10,026,773<ref name="wikidata-a320e0a81aa82b19d4b7f1b9e71f39c153da28ab-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&D1=a&D2=0,10,20,30,40,50,60,(l-1),l&HD=130605-0924&HDR=G1&STB=T; retrieved: 22 August 2015; publisher: Statistics Netherlands.</ref><ul><li>1950</li></ul></li> <li>17,000,000<ref name="wikidata-928a3addb389f1dc02548a71c7d09a2a7f8ba2f9-v3">http://www.cbs.nl/nl-NL/menu/themas/bevolking/publicaties/artikelen/archief/2016/nederland-telt-17-miljoen-inwoners.htm.</ref><ul><li>21 March 2016</li></ul></li> <li>17,132,854<ref name="wikidata-b9afa65b0872528113472db065673a53e65e8a2f-v3">https://data.worldbank.org/indicator/SP.POP.TOTL; ''World Bank Open Data''; retrieved: 8 April 2019.</ref><ul><li>2017</li></ul></li> <li>17,181,084<ref name="wikidata-6fec2588a9340c9877ba4ab2916567f018ea0986-v3">https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.</ref><ul><li>1 January 2018</li></ul></li></ul> | ||
+ | | Returns the output in a custom format. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''qualifier'''|normal+|Q55|P1082|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :2019; 26 August 2014; 2013; 1950; 21 March 2016; 2017; 1 January 2018 | ||
+ | | Gets a single qualifier per claim, by default for multiple matching claims. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|qualifier|normal+|'''single'''|Q55|P1082|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :2019 | ||
+ | | To get a single qualifier for only a single claim, give the <code>single</code> flag too so that only a single claim will be accessed. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|qualifier|Q55|P1082|'''16829289'''|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :26 August 2014 | ||
+ | | Gets a qualifier from claims for which the (raw) property value matches a given literal value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|qualifier|'''mdy'''|Q55|P1082|16829289|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :August 26, 2014 | ||
+ | | Gets dates in month-day-year order. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population", P585 = "point in time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|qualifier|'''raw'''|Q55|P1082|16829289|P585|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :2014-08-26 | ||
+ | | Gets a raw date value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''references'''|Q55|P1082|'''16829289'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :<ref name="wikidata-cea8d68b073c3e015eb19fca29cfdd632fc42c65-v3">http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&LA=NL; retrieved: 26 August 2014.</ref> | ||
+ | | Gets the references from a particular claim. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1082 = "population"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''references'''|'''raw'''|Q55|P1082|'''16829289'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&LA=NL; retrieved: 26 August 2014. | ||
+ | | Gets references from a particular claim in their raw form. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P1081|P1081]] = "Human Development Index"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''references'''|normal+|Q55|P1081|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :0.922,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.787, 0.799, 0.829,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref><ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.861,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.877,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.891,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.909,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.919,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.920,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.920,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.834,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.835,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.839,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.864,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.866,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.865,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.867,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.870,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.876,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.879,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.878,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.883,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.886,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.897,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.904,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.906,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.906,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.910,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.921,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.921,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.923,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.924,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.926,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.928,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.931<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> | ||
+ | | Gets properties from each claim with any references they have. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1081 = "Human Development Index"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|references|normal+|'''sourced'''|Q55|P1081|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :0.922,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.829,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref><ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.861,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.877,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.891,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.909,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.919,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.920,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.920,<ref name="wikidata-b390d962385d11d1a0d3d91d37b0d2bab9340356-v3">http://hdr.undp.org/en/countries/profiles/NLD.</ref> 0.834,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.835,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.839,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.864,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.866,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.865,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.867,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.870,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.876,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.879,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.878,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.883,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.886,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.897,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.904,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.906,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.906,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.910,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.921,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.921,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.923,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.924,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.926,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.928,<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> 0.931<ref name="wikidata-f8bd5a2dc99b1b77fa36f065ae4c79b3eb476ef0-v3">http://hdr.undp.org/en/data; ''[[Human Development Report]]''.</ref> | ||
+ | | Only gets properties from claims that have at least one reference. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P2855|P2855]] = "VAT-rate", [[d:Property:P518|P518]] = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''qualifier'''|Q55|P2855|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :food | ||
+ | | Gets a single qualifier value (for each matching claim). | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''qualifiers'''|Q55|P2855|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :food, medication, assistive technology, magazine, book, art, antique, hairdresser, hotel, campsite, recreation, sport, water | ||
+ | | Gets multiple qualifier values (for each matching claim). | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''properties'''|qualifiers|Q55|P2855|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :21%, 6% <span style="font-size:85%">(food, medication, assistive technology, magazine, book, art, antique, hairdresser, hotel, campsite, recreation, sport, water)</span> | ||
+ | | Gets multiple property values along with multiple qualifier values. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}], [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifiers|Q55|P2855|P518|'''sep{{=}}_+_'''|'''sep%s{{=}}'''|'''sep%q{{=}}_/_'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :21% + 6% <span style="font-size:85%">(food / medication / assistive technology / magazine / book / art / antique / hairdresser / hotel / campsite / recreation / sport / water)</span> | ||
+ | | Returns the output with custom separators. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P35|P35]] = "head of state", [[d:Property:P580|P580]] = "start time", [[d:Property:P582|P582]] = "end time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''qualifier'''|'''qualifier'''|normal+|Q55|P35|'''P580'''|'''P582'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Willem-Alexander of the Netherlands <span style="font-size:85%">(30 April 2013)</span>, Beatrix of the Netherlands <span style="font-size:85%">(30 April 1980; 30 April 2013)</span>, Juliana of the Netherlands <span style="font-size:85%">(4 September 1948; 30 April 1980)</span>, Wilhelmina of the Netherlands <span style="font-size:85%">(23 November 1890; 4 September 1948)</span>, William III of the Netherlands <span style="font-size:85%">(17 March 1849; 23 November 1890)</span>, William II of the Netherlands <span style="font-size:85%">(7 October 1840; 17 March 1849)</span>, William I of the Netherlands <span style="font-size:85%">(16 March 1815; 7 October 1840)</span> | ||
+ | | Gets two different qualifier values for each claim. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|qualifier|normal+|Q55|P35|P580|P582|'''sep%q{{=}}_–_'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Willem-Alexander of the Netherlands <span style="font-size:85%">(30 April 2013)</span>, Beatrix of the Netherlands <span style="font-size:85%">(30 April 1980 – 30 April 2013)</span>, Juliana of the Netherlands <span style="font-size:85%">(4 September 1948 – 30 April 1980)</span>, Wilhelmina of the Netherlands <span style="font-size:85%">(23 November 1890 – 4 September 1948)</span>, William III of the Netherlands <span style="font-size:85%">(17 March 1849 – 23 November 1890)</span>, William II of the Netherlands <span style="font-size:85%">(7 October 1840 – 17 March 1849)</span>, William I of the Netherlands <span style="font-size:85%">(16 March 1815 – 7 October 1840)</span> | ||
+ | | Returns the output with a custom separator. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|qualifier|normal+|Q55|P35|P580|P582|'''<nowiki>format=%p[ <span style="font-size:85\%">(%q1[ – %q2])</span>][%s][%r]</nowiki>'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Willem-Alexander of the Netherlands <span style="font-size:85%">(30 April 2013)</span>, Beatrix of the Netherlands <span style="font-size:85%">(30 April 1980 – 30 April 2013)</span>, Juliana of the Netherlands <span style="font-size:85%">(4 September 1948 – 30 April 1980)</span>, Wilhelmina of the Netherlands <span style="font-size:85%">(23 November 1890 – 4 September 1948)</span>, William III of the Netherlands <span style="font-size:85%">(17 March 1849 – 23 November 1890)</span>, William II of the Netherlands <span style="font-size:85%">(7 October 1840 – 17 March 1849)</span>, William I of the Netherlands <span style="font-size:85%">(16 March 1815 – 7 October 1840)</span> | ||
+ | | Returns the output in a custom format instead of with a custom separator. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|qualifier|normal+|Q55|P35|P580|P582|<nowiki>format=%p[ <span style="font-size:85\%">(</nowiki>'''<nowiki>[<![]--%q2]since [%q2--[]>]</nowiki>'''<nowiki>%q1[ – %q2])</span>][%s][%r]</nowiki>|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Willem-Alexander of the Netherlands <span style="font-size:85%">(since 30 April 2013)</span>, Beatrix of the Netherlands <span style="font-size:85%">(<!--30 April 2013since 30 April 2013-->30 April 1980 – 30 April 2013)</span>, Juliana of the Netherlands <span style="font-size:85%">(<!--30 April 1980since 30 April 1980-->4 September 1948 – 30 April 1980)</span>, Wilhelmina of the Netherlands <span style="font-size:85%">(<!--4 September 1948since 4 September 1948-->23 November 1890 – 4 September 1948)</span>, William III of the Netherlands <span style="font-size:85%">(<!--23 November 1890since 23 November 1890-->17 March 1849 – 23 November 1890)</span>, William II of the Netherlands <span style="font-size:85%">(<!--17 March 1849since 17 March 1849-->7 October 1840 – 17 March 1849)</span>, William I of the Netherlands <span style="font-size:85%">(<!--7 October 1840since 7 October 1840-->16 March 1815 – 7 October 1840)</span> | ||
+ | | To add text only when a certain value is not present, like adding the word ''since'' if there is no end time, wrap it in between two optional blocks containing HTML comment tags and the relevant parameter (this also prevents the text from being added to the page source). | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P35 = "head of state", [[d:Q29574|Q29574]] = "Beatrix of the Netherlands", P580 = "start time", P582 = "end time"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|time}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifier|'''raw'''|qualifier|normal+|Q55|P35|'''Q29574'''|P580|P582|<nowiki>format=%p[ <span style="font-size:85\%">(%q1[ – %q2])</span>][%s][%r]</nowiki>|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Beatrix of the Netherlands <span style="font-size:85%">(1980-04-30 – 30 April 2013)</span> | ||
+ | | Gets a property with qualifiers from claims for which the property matches a given Q-identifier, with one of the qualifier values in its raw form. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P38|P38]] = "currency", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifiers|normal+|'''current'''|Q55|P38|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :euro <span style="font-size:85%">(European Netherlands)</span>, United States dollar <span style="font-size:85%">(Caribbean Netherlands)</span> | ||
+ | | Gets claims that are currently valid. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''linked'''|qualifiers|normal+|current|Q55|P38|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[Euro|euro]] <span style="font-size:85%">(European Netherlands)</span>, [[United States dollar]] <span style="font-size:85%">(Caribbean Netherlands)</span> | ||
+ | | Gets claims with linked property values. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|qualifiers|'''linked'''|normal+|current|Q55|P38|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :euro <span style="font-size:85%">(European Netherlands)</span>, United States dollar <span style="font-size:85%">([[Caribbean Netherlands]])</span> | ||
+ | | Gets claims with linked qualifier values. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''linked'''|'''short'''|qualifiers|'''linked'''|normal+|current|Q55|P38|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[Euro|euro]] <span style="font-size:85%">(European Netherlands)</span>, [[United States dollar|US dollar]] <span style="font-size:85%">([[Caribbean Netherlands]])</span> | ||
+ | | Gets claims with linked property and qualifier values, with short property values wherever available. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency", [[d:Q4917|Q4917]] = "United States dollar", P518 = "applies to part"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|qualifiers|normal+|current|Q55|P38|'''Q4917'''|P518|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Caribbean Netherlands | ||
+ | | Gets qualifiers from claims for which the (raw) property value matches a given Q-identifier. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency", P518 = "applies to part", [[d:Q27561|Q27561]] = "Caribbean Netherlands"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|normal+|current|Q55|P38|'''P518{{=}}Q27561'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :United States dollar | ||
+ | | Gets properties from claims for which a (raw) qualifier value matches a given Q-identifier. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|normal+|'''former'''|Q55|P38|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Dutch guilder | ||
+ | | Gets claims that were valid in the past. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|'''raw'''|normal+|former|Q55|P38|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Q788472 | ||
+ | | Gets raw property values. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P38 = currency"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|raw|'''linked'''|normal+|former|Q55|P38|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[d:Q788472|Q788472]] | ||
+ | | Gets raw property values that are linked to Wikidata. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P1549|P1549]] = "demonym"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|monolingual text}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q55|P1549|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Dutch | ||
+ | | Gets a monolingual text value in the current wiki's language. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P1549 = "demonym", [[d:Property:P407|P407]] = "language of work or name", [[d:Q36846|Q36846]] = "Toki Pona"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|monolingual text}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''multilanguage'''|Q55|P1549|P407{{=}}Q36846|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :jan Netelan | ||
+ | | Gets a monolingual text value in any available language. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P2884|P2884]] = "mains voltage"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q55|P2884|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :230 volt | ||
+ | | Gets a quantity value with its associated unit of measurement. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2884 = "mains voltage"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''linked'''|Q55|P2884|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :230 [[Volt|volt]] | ||
+ | | Gets a quantity value with a linked unit of measurement. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2884 = "mains voltage"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''raw'''|Q55|P2884|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :230 | ||
+ | | Gets a raw quantity value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2884 = "mains voltage"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''unit'''|Q55|P2884|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :volt | ||
+ | | Gets only the unit of measurement. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P2884 = "mains voltage"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|quantity}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|unit|'''raw'''|Q55|P2884|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Q25250 | ||
+ | | Gets the raw unit of measurement. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P625|P625]] = "coordinate location"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|globe coordinate}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q55|P625|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :52°19'N, 5°33'E | ||
+ | | Gets a globe coordinate value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P625 = "coordinate location"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|globe coordinate}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''linked'''|Q55|P625|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[https://tools.wmflabs.org/geohack/geohack.php?language=en¶ms=52_19_N_5_33_E_globe:earth 52°19'N, 5°33'E] | ||
+ | | Gets a linked globe coordinate value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P625 = "coordinate location"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|globe coordinate}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''raw'''|Q55|P625|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :52/19/N/5/33/E | ||
+ | | Gets a raw globe coordinate value. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P625 = "coordinate location"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|globe coordinate}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q55|'''coord'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :52°19'N, 5°33'E | ||
+ | | A property alias can be used instead of the P-identifier. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", [[d:Property:P41|P41]] = "flag image"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|commons media}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''linked'''|Q55|P41|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[c:File:Flag of the Netherlands.svg|Flag of the Netherlands.svg]] | ||
+ | | Gets a media file name and links to it on Commons. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P41 = "flag image"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|commons media}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''raw'''|Q55|P41|'''<nowiki>format=\[\[File:%p {{!}} thumb {{!}} left\]\]</nowiki>'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[File:Flag of the Netherlands.svg{{!}} thumb {{!}} left]] | ||
+ | | A Commons media file can be included on the page as-is by omitting the <code>linked</code> and <code>raw</code> flags, but by using the <code>raw</code> flag it can be freely formatted. | ||
+ | |||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P41 = "flag image"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|commons media}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|raw|'''date{{=}}1700-05-06'''|Q55|P41|<nowiki>format=\[\[File:%p {{!}} thumb {{!}} left\]\]</nowiki>|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[File:Statenvlag.svg{{!}} thumb {{!}} left]] | ||
+ | | To get the value of a property that was valid at a given time, the <code>date=</code> argument can be used. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands", P41 = "flag image"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|commons media}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|raw|date{{=}}1700-05-06|'''former'''|Q55|P41|<nowiki>format=\[\[File:%p {{!}} thumb {{!}} left\]\]</nowiki>|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[File:Prinsenvlag.svg{{!}} thumb {{!}} left]] | ||
+ | | The time constraint flags work relatively to the date value given for the <code>date=</code> argument. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q915684|Q915684]] = "Lorentz–Lorenz equation", [[d:Property:P2534|P2534]] = "defining formula"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|math}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|Q915684|P2534|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :<math qid="Q915684">\frac{n^2 - 1}{n^2 + 2} = \frac{4 \pi}{3} N \alpha</math> | ||
+ | | Gets a mathematical expression. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q915684 = "Lorentz–Lorenz equation", [[d:Property:P527|P527]] = "has part", [[d:Property:P416|P416]] = "quantity symbol (string)", P2534 = "defining formula"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}], [{{smallcaps|string}}], [{{smallcaps|math}}] | ||
+ | | <code><nowiki><ul></nowiki>{{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|properties|linked|qualifier|qualifier|Q915684|P527|P416|P2534|<nowiki>format=<li>%p[ (%q)]</li></nowiki>|{{{extraparams|}}}}}<nowiki></ul></nowiki></code><br /> | ||
+ | :↓<br /> | ||
+ | :<ul><li>[[Refractive index|refractive index]] (n)</li> <li>[[Polarizability|polarizability]] (<math qid="Q915684">\alpha</math>)</li> <li>[[Number density|number density]] (N)</li> <li>[[Pi|pi]] (<math qid="Q915684">\pi</math>)</li></ul> | ||
+ | | Mathematical expressions can be combined with regular text as usual. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q6256|Q6256]] = "country", [[d:Property:P3896|P3896]] = "geoshape"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|geographic shape}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|'''linked'''|Q6256|P3896|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[c:Data:Naturalearthdata.com/admin-0-countries-no-antarctica.map|Data:Naturalearthdata.com/admin-0-countries-no-antarctica.map]] | ||
+ | | Gets a geographic shape data file name and links to it on Commons. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q4917 = "United States dollar"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''label'''|Q4917|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :United States dollar | ||
+ | | Gets an item's label. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q4917 = "United States dollar"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|'''short'''|'''linked'''|Q4917|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[United States dollar|US dollar]] | ||
+ | | Gets an item's short and linked label. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | P38 = currency"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|P38|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :currency | ||
+ | | Gets a property's label. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | P38 = currency"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|'''linked'''|P38|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[d:Property:P38|currency]] | ||
+ | | Gets a property's label that is linked to Wikidata. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q776|Q776]] = "Utrecht"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|Q776|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Utrecht | ||
+ | | Gets an item's label. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q776 = "Utrecht"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|'''linked'''|Q776|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[Utrecht (province)|Utrecht]] | ||
+ | | Gets an item's linked label. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Utrecht | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Utrecht (province)]] page (which is linked to Q776), then the <code>Q776</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|'''raw'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Q776 | ||
+ | | If just the <code>label</code> command with the <code>raw</code> flag is given, then the Q-identifier of the item connected to the current page is returned. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity label}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|label|raw|'''linked'''|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[d:Q776|Q776]] | ||
+ | | If additionally the <code>linked</code> flag is given, then the Q-identifier of the item connected to the current page is linked to Wikidata. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q776 = "Utrecht"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page title}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''title'''|Q776|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Utrecht (province) | ||
+ | | Gets the title of the page on the current wiki that is linked to the given item. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q776 = "Utrecht"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page title}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|title|'''linked'''|Q776|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[Utrecht (province)]] | ||
+ | | Gets the linked title of the page on the current wiki that is linked to the given item. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page title}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|title|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Utrecht (province) | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Utrecht (province)]] page (which is linked to Q776), then the <code>Q776</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity description}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''description'''|Q55|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :country in western Europe | ||
+ | | Gets an item's description. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity description}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|description|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :country in western Europe | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Netherlands]] page (which is linked to Q55), then the <code>Q55</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity alias}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''alias'''|Q55|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Holland | ||
+ | | Gets one of an item's aliases. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity alias}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''aliases'''|Q55|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Holland, the Netherlands, NL, NED, Nederland, nl, 🇳🇱, Netherlands (after 1945) | ||
+ | | Gets all of an item's aliases. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q55 = "Netherlands"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity alias}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|alias|'''linked'''|Q55|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :[[Netherlands|Holland]] | ||
+ | | Gets a linked alias from an item. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|entity alias}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|alias|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Holland | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Netherlands]] page (which is linked to Q55), then the <code>Q55</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q2|Q2]] = "Earth"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page badge}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|'''badges'''|Q2|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :featured article badge | ||
+ | | Gets the badges for the page on the current wiki that is linked to the given item. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | Q2 = "Earth"<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page badge}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|badges|'''raw'''|Q2|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :Q17437796 | ||
+ | | Gets the raw badges for the page on the current wiki that is linked to the given item. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | <br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|page badge}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|badges|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :featured article badge | ||
+ | | If the {{lcfirst:{{NAMESPACE}}}} is transcluded on the [[Earth]] page (which is linked to Q2), then the <code>Q2</code> can be omitted. | ||
+ | |- | ||
+ | | style="color:#777;font-size:small;" | [[d:Q28865|Q28865]] = "Python", [[d:P548|P548]] = "version type", [[d:P348|P348]] = "software version identifier",<br /> | ||
+ | :↓<br /> | ||
+ | [{{smallcaps|version}}], [{{smallcaps|reference}}] | ||
+ | | {{tnull|{{{prename|}}}{{lcfirst:{{BASEPAGENAME}}}}|property|reference|edit|Q28865|'''P548{{=}}Q2804309'''|P348|{{{extraparams|}}}}}<br /> | ||
+ | :↓<br /> | ||
+ | :3.9.1<ref name="wikidata-ba26ae53d9121f3dd8ba5c1091f58b764835bd74-v3">{{Cite web|date=7 December 2020|url=https://pythoninsider.blogspot.com/2020/12/python-391-is-now-available-together.html|title=Python 3.9.1 is now available, together with 3.10.0a3 and 3.8.7rc1|access-date=8 December 2020}}</ref> [[File:OOjs UI icon edit-ltr-progressive.svg|frameless|text-top|10px|alt=Edit this on Wikidata|link=https://www.wikidata.org/wiki/Q28865?uselang=en#P348|Edit this on Wikidata]] | ||
+ | | Get [[Python (programming language)|Python]]'s latest stable release version with its references. You may want to use '''P548{{=}}Q2122918''' to get the lastest preview release version. | ||
+ | |} | ||
+ | |||
+ | === Example references === | ||
+ | {{Reflist}} | ||
+ | |||
+ | == See also == | ||
+ | {{module other|*{{t|Wikidata}}, a user-friendly wrapper template for this module. | ||
+ | *{{t|WikidataOI}}, a wrapper template for this module that adds an opt-in toggle.|{{{seealso|}}} | ||
+ | *[[Module:Wd]], the source module that is called by this template | ||
+ | *{{t|Wikidata entity link}} or redirect {{t|Q}}), to add a Wikidata entity link to a Wikipedia page | ||
+ | *{{t|Wikidata property link}} or redirect {{t|Property}}, to add a Wikidata property link to a Wikipedia page | ||
+ | *{{t|Wikidata property}}, to add a Wikidata property {{t|side box}} to a Wikipedia page or template documentation | ||
+ | *{{t|Uses Wikidata}}, to add a Wikidata property box to the documentation of a template or module | ||
+ | *{{t|Tracks Wikidata}}, to add a Wikidata property box to the documentation of a template, module, or category | ||
+ | }} | ||
+ | *{{t|Pageid to title}}, to get a page title using its local page id, rather than Wikidata | ||
+ | |||
+ | <includeonly><!-- /doc page is transcluded on these two root pages: -->{{#switch:{{NAMESPACE}}:{{PAGENAME}} | ||
+ | |Module:Wd = [[Category:Wikidata modules]][[Category:Modules using data from Wikidata]] | ||
+ | |Template:WikidataOI |Template:Wikidata = [[Category:Wikidata templates]] | ||
+ | }}</includeonly> |
Latest revision as of 13:00, 25 March 2021
Lua error: Internal error: The interpreter exited with status 127. Script error: No such module "Hatnote". This module is intended to fetch data from Wikidata with or without a link to the connected Wikipedia article and with many other features.
Usage
The general structure of a call to this module is as follows. Note that the basic structure consists of positional commands, flags and arguments, which all have a fixed position.
- Lua error: Internal error: The interpreter exited with status 127.
Use different commands to get different kinds of values from Wikidata. At least one command must be given and multiple commands can be combined into one call as shown above (in any order, more than two is also possible), but this only applies to commands from the claim class; calls containing a command from the general class cannot contain any other command. Each command can be followed by any number of command flags, which are optional and can be used to tweak the output generated by that command.
The commands and their flags may be followed by any number of configuration flags, which are also optional and affect the selection of data and the module's behaviour in general. The call is closed with the positional arguments, which may be required depending on the given command(s). Some named arguments (i.e. name-value pairs) also exist, as well as a set of named flags for advanced usage that can be used to change the way the fetched values are merged together into the output.
This module was designed to provide the basic needs for fetching data from Wikidata, but a lot can be achieved through different combinations of calls. For convenience, such combinations could be wrapped into new templates that serve a specific need. See also the section on common use cases below for some examples of useful "building blocks". Likewise, the functionality of this module can be extended by creating wrapper templates that use the main
command provided by this module (just like {{WikidataOI}} does).
Common use cases
Below follows a list of common use cases. In the future, shortcut commands may be implemented that are equivalent to these calls for convenience.
Call | Use case |
---|---|
Lua error: Internal error: The interpreter exited with status 127. | Returns the Q-identifier of the Wikidata item connected to the current page (e.g. "Q55"). |
{{#if:Lua error: Internal error: The interpreter exited with status 127.|...}}
|
Performs a check to determine if the current page has a Wikidata item.
Note that this statement relies on a returned value that is either empty or non-empty and that the |
Commands
The commands (command1
, command2
, ...) determine what kind of values are returned. One call can only contain commands from a single class.
Claim class
The claim class commands can be combined, meaning that multiple commands of different types from this class can be given at one time (see above for usage).
Combine multiple commands into one call to this module, instead of making multiple calls to this module with one command each, to be sure that all the returned pieces of information belong to each other (see also the examples below).
Type | Command | Returns | Basic usage | Description |
---|---|---|---|---|
I | property
|
first match[lower-alpha 1] | Lua error: Internal error: The interpreter exited with status 127. | Returns the requested property – or list of properties – from the current item-entity or from a given entity.
This command can be given only once in one call. |
properties
|
all matches | Lua error: Internal error: The interpreter exited with status 127. | ||
II | qualifier
|
first match[lower-alpha 2] | Lua error: Internal error: The interpreter exited with status 127. | Returns the requested qualifier – or list of qualifiers – from the given property of the current item-entity or of a given entity.
Unlike the other claim class commands, this command can be given multiple times to retrieve different qualifiers in one call. |
qualifiers
|
all matches | Lua error: Internal error: The interpreter exited with status 127. | ||
III | reference
|
first match[lower-alpha 2] | Lua error: Internal error: The interpreter exited with status 127. | Returns a reference – or list of references – from the given property of the current item-entity or of a given entity.[lower-alpha 3]
This command can be given only once in one call. |
references
|
all matches | Lua error: Internal error: The interpreter exited with status 127. | ||
|
General class
The general class commands cannot be combined.
Type | Command | Returns | Basic usage | Description |
---|---|---|---|---|
I | label
|
Lua error: Internal error: The interpreter exited with status 127. | Returns the label of the current item-entity or of a given entity if present. | |
II | title
|
Lua error: Internal error: The interpreter exited with status 127. | Returns the title of the page connected to the current item-entity or to a given item-entity if such page exists. | |
III | description
|
Lua error: Internal error: The interpreter exited with status 127. | Returns the description of the current item-entity or of a given entity if present. | |
IV | alias
|
first match[lower-alpha 1] | Lua error: Internal error: The interpreter exited with status 127. | Returns an alias – or list of aliases – of the current item-entity or of a given entity if present. |
aliases
|
all matches | Lua error: Internal error: The interpreter exited with status 127. | ||
V | badge
|
first match[lower-alpha 1] | Lua error: Internal error: The interpreter exited with status 127. | Returns a badge – or list of badges – for the page connected to the current item-entity or to a given item-entity if such page exists. |
badges
|
all matches | Lua error: Internal error: The interpreter exited with status 127. | ||
Lua error: Internal error: The interpreter exited with status 127. |
Flags
The following (optional) flags are available which can be used to alter this module's behaviour. They must be given after the (first) command and before the positional arguments. For convenience, empty flags (i.e. ||
) are allowed and will simply be ignored.
Command flags
These flags (flag1*
, flag2*
, ...) apply to the command that precedes them directly.
Flag | Description |
---|---|
raw
|
Returns the raw value if applicable.
If this flag is used with item or property datatypes, then this will return the Q-identifier or P-identifier instead of the regular label. For quantity datatypes, this flag will strip off any units of measurement, unless the If this flag is used with time datatypes, then the returned date will be in the format of If it is used with globe coordinate datatypes, then it replaces the various symbols with forward slashes in the returned value (e.g. |
linked
|
Creates a link to the Wikipedia article that is connected to the property or qualifier if it exists. Also links units of measurement that may be appended to values.
If this parameter is omitted, then the plain property or qualifier value will be returned. |
short
|
[EXPENSIVE] Returns the Lua error: Internal error: The interpreter exited with status 127. (P1813) of any entity returned if they have one attached. If that is not the case, then the default behaviour of returning the entity's label will occur.
|
multilanguage
|
Returns monolingual text values in any available language, not just the current wiki's language. |
unit
|
Returns only the unit of measurement for quantity datatypes. |
Configuration flags
These flags (flag0*
) are general configuration flags and can be given anywhere after the first command (but before the positional arguments).
Flag | Description | Command class | |
---|---|---|---|
Combination of: | preferred
|
Sets a rank constraint for the selected claim(s).
The first three set the ranks for which claim(s) will be selected. They can optionally be followed by a If the The default is Output is always sorted from highest rank to lowest (regardless of any of these flags being set). |
claim |
normal
| |||
deprecated
| |||
best
| |||
Combination of: | future
|
Sets a time constraint for the selected claim(s). Uses the claims' qualifiers of Lua error: Internal error: The interpreter exited with status 127. (P580) and Lua error: Internal error: The interpreter exited with status 127. (P582) to determine if the claim is valid for the selected time period(s).
The default is |
claim |
current
| |||
former
| |||
mdy
|
Returns date values in month-day-year order instead of day-month-year order. | claim | |
single
|
Returns only a single claim instead of multiple (if multiple claims match). Has no effect if the property /properties command is given, in which case this flag would be redundant.
|
claim | |
sourced
|
Only returns claims that have at least one valid reference. | claim | |
One of: | edit
|
Adds a clickable icon after the output that may be used by readers to edit the returned claim on Wikidata.
If |
claim, general |
edit@end
|
Arguments
The arguments determine the sources from which all the returned values are fetched.
Positional arguments
The following table shows the available positional arguments (arg*
) in their fixed order. For each command, the applicable set of arguments is marked. If multiple commands are given, then the applicable set is the union of the individual sets. For instance, if the commands properties
and qualifiers
have been given, then at least both the arguments property_id
and qualifier_id
should be given as well.
More than one qualifier
/qualifiers
command can be given. The order in which these commands with their flags are given matches the order in which the respective qualifier_id
arguments are given.
(required) | (optional) | (optional) | (required) | (optional) | (required) | (required) | |||
{{wd
|
commands
|
flags
|
entity_id
|
property_id
|
raw_value
|
qualifier_id
|
qualifier_id
|
}}
| |
---|---|---|---|---|---|---|---|---|---|
label , title ,description ,alias /aliases ,badge /badges
|
|||||||||
property /properties
|
|||||||||
reference /references
|
|||||||||
qualifier /qualifiers
|
|||||||||
qualifier /qualifiers (optional 2nd, 3rd, etc.)
| |||||||||
Below follows a description of all positional arguments.
Argument | Description |
---|---|
entity_id
(optional) |
[EXPENSIVE] Q-identifier of the item-entity to be accessed (e.g. Q55 ), P-identifier (or an available alias) of the property-entity to be accessed preceded by the Property: prefix (e.g. Property:P38 ), or page title of the Wikipedia article whose connected item-entity is to be accessed preceded by : , a prefixed colon (e.g. :Netherlands ).
In case of the general class commands, the If this parameter is omitted, then the item-entity connected to the current page will be used (except when |
property_id
|
P-identifier (or an available alias) of the property within the entity to be accessed, without the Property: prefix (e.g. P35 ).
|
raw_value
(optional) |
Either the Q-identifier equal to the property value (e.g. Q29574 ) or a literal value (i.e. string or quantity etc., no entity label) equal to the raw property value of the particular claim to be accessed.
Dates as literal values must be formatted Globe coordinates as literal values must be formatted with forward slashes (i.e. The special type 'no value' can be given by entering the empty string (i.e. To get a literal vertical bar If this parameter is omitted, then all claims (matching any other constraints) within the property will be accessed. |
qualifier_id
|
P-identifier (or an available alias) of the qualifier within the entity to be accessed, without the Property: prefix (e.g. P580 ).
|
Named arguments
Below follows a description of all named arguments, which are name-value pairs (i.e. |name=value
). These are all optional and can be given anywhere after the first command.
Argument | Description | Command class |
---|---|---|
eid=
|
[EXPENSIVE] This argument can be used to give the Q-identifier (e.g. |eid=Q55 ) or P-identifier (or an available alias) of the entity to be accessed. It offers the same functionality as the positional argument entity_id , with one difference: if the argument is given but its value is left empty (i.e. |eid= ), then no entity is accessed at all instead of the item-entity connected to the current page. This is useful in some cases where a variable entity-ID is expected, but where the item-entity connected to the current page should not be accessed as the default.
Also, the This argument only has effect if the positional argument |
claim, general |
page=
|
[EXPENSIVE] This argument can be used to give the page title (e.g. |page=Netherlands ) of the Wikipedia article whose connected item-entity is to be accessed. It behaves similar to the named argument eid= and can be used instead of the positional argument entity_id (note that no prefixed colon, : , is required). If the argument is given but its value is left empty (i.e. |page= ), then no entity is accessed at all instead of the item-entity connected to the current page.
This argument only has effect if the positional argument |
claim, general |
date=
|
This argument can be used to set a particular date (e.g. |date=1731-02-11 ) relative to which claim matching using the future , current and former flags is done, instead of relative to today. It overrides the default of these flags to current so that by default only claims that were valid at the given date are returned (based on the claims' qualifiers of Lua error: Internal error: The interpreter exited with status 127. (P580) and Lua error: Internal error: The interpreter exited with status 127. (P582)).
The date value must be formatted |
claim |
<qualifier>=
|
The <qualifier> is a placeholder for a set of arguments that determine which claims should be accessed based on qualifier value, analogous to the pair of positional arguments property_id and raw_value (that determine access based on property value).
As such, Example: Multiple arguments of this type can be given to match multiple qualifier values simultaneously for each claim. |
claim |
Property aliases
Property aliases are other names for P-identifiers that can be used instead. The following property aliases (which are case-sensitive) are currently available:
Alias | translates to |
P-identifier |
---|---|---|
coord | → | P625 |
image | → | P18 |
author | → | P50 |
publisher | → | P123 |
importedFrom | → | P143 |
statedIn | → | P248 |
pages | → | P304 |
language | → | P407 |
hasPart | → | P527 |
publicationDate | → | P577 |
startTime | → | P580 |
endTime | → | P582 |
chapter | → | P792 |
retrieved | → | P813 |
referenceURL | → | P854 |
sectionVerseOrParagraph | → | P958 |
archiveURL | → | P1065 |
title | → | P1476 |
formatterURL | → | P1630 |
quote | → | P1683 |
shortName | → | P1813 |
definingFormula | → | P2534 |
archiveDate | → | P2960 |
inferredFrom | → | P3452 |
typeOfReference | → | P3865 |
column | → | P3903 |
Advanced usage
The layout of the output from (a combination of) commands that have both a singular and a plural form (e.g. property
/properties
) can be customized by using a number of named flags, which are name-value pairs (i.e. |flag=value
), that can be given anywhere after the first command. The table below shows the available named flags.
To insert a space at the beginning or end of a value
, use an underscore _
. To get a literal underscore, escape it by placing a backslash \
directly in front of it (i.e. \_
); the same holds for a literal backslash (i.e. \\
). To get a literal vertical bar |
, use {{!}}
or |
.
Named flag | Default value | Default condition | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
format=
|
%p[%s][%r]
|
if the property /properties command was given and the qualifier /qualifiers command was not given
|
The format of a single claim. The available parameters are as follows.
Optional parameters can be given by encapsulating them between square brackets: To use two opening square brackets that directly follow each other (i.e. At least one parameter must be given that is not optional, while the To get a literal | ||||||||||||||||
%q[%s][%r]
|
if the property /properties command was not given and the qualifier /qualifiers command was given
| ||||||||||||||||||
%r
|
if only the reference /references command was given
| ||||||||||||||||||
%p[ <span style="font-size:85\%">(%q)</span>][%s][%r]
|
if the property /properties command was given and the qualifier /qualifiers command was given
| ||||||||||||||||||
%a[%s]
|
if the alias /aliases command was given
| ||||||||||||||||||
%b[%s]
|
if the badge /badges command was given
| ||||||||||||||||||
sep=
|
_
|
default | The fixed separator between each pair of claims, aliases or badges. | ||||||||||||||||
|
if only the reference /references command was given without the raw flag
| ||||||||||||||||||
sep%s=
|
,
|
default | The movable separator between each pair of claims, aliases or badges. This will be the value of the %s parameter applied to all claims, aliases or badges, except for the last in the list (which can be set with the punc flag).
| ||||||||||||||||
;
|
if the property /properties command was not given and the qualifier /qualifiers command was given
| ||||||||||||||||||
sep%q1= , sep%q2= , sep%q3= , ...
|
,_
|
default | The separator between each pair of qualifiers of a single claim. These are the value separators for the %q1 , %q2 , %q3 , ... parameters.
If only one | ||||||||||||||||
sep%q=
|
,_
|
if exactly one qualifier /qualifiers command was given
|
The separator between each set of qualifiers of a single claim. This is the value separator for the %q parameter.
If only one | ||||||||||||||||
;_
|
if more than one qualifier /qualifiers command was given
| ||||||||||||||||||
sep%r=
|
|
default | The separator between each pair of references of a single claim. This is the value separator for the %r parameter.
| ||||||||||||||||
_
|
if the raw flag was given for the reference /references command
| ||||||||||||||||||
punc=
|
|
default | A punctuation mark placed at the end of the output. This will be placed on the %s parameter applied to the last claim (or alias or badge) in the list.
This allows the last claim's references to be placed after the punctuation mark when the output is used as part of a sentence. |
Examples
Parameters and output types | Example | Description |
---|---|---|
Q55 = "Netherlands", P395 = "licence plate code"
[string] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a literal string value. |
P395 = "licence plate code"
[string] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Netherlands page (which is linked to Q55), then the Q55 can be omitted.
|
Q55 = "Netherlands", P395 = "NL"
[string] |
Lua error: Internal error: The interpreter exited with status 127.
|
An entity-ID can also be given using the eid= argument.
|
P395 = "NL"
[string] |
Lua error: Internal error: The interpreter exited with status 127.
|
A page title can be given instead of an entity-ID using the page= argument.
|
Q55 = "Netherlands", P395 = "licence plate code"
[string] |
Lua error: Internal error: The interpreter exited with status 127. |
Adds a clickable icon that may be used to edit the returned value on Wikidata. |
Q55 = "Netherlands", P395 = "licence plate code"
[string] |
Lua error: Internal error: The interpreter exited with status 127. |
Places the edit icon at the end of the line. |
Q55 = "Netherlands", P1082 = "population"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a single property value from claims with a 'normal' rank or higher. |
Q55 = "Netherlands", P1082 = "population"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets multiple property values from claims with a 'normal' rank or higher. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[quantity], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a single qualifier value for each claim, additional to the property value. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[quantity], [time], [reference] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets references for each claim. |
Q55 = "Netherlands", P1082 = "population"
[quantity], [reference] |
A total of Lua error: Internal error: The interpreter exited with status 127. people live in the Netherlands.
|
Gets a property with its references. |
Q55 = "Netherlands", P1082 = "population"
[quantity], [reference] |
The Netherlands has a population of Lua error: Internal error: The interpreter exited with status 127.
|
Adds a punctuation mark at the end of the output, in front of the references. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[quantity], [time], [reference] |
<ul>Lua error: Internal error: The interpreter exited with status 127.</ul>
|
Returns the output in a custom format. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a single qualifier per claim, by default for multiple matching claims. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[time] |
Lua error: Internal error: The interpreter exited with status 127.
|
To get a single qualifier for only a single claim, give the single flag too so that only a single claim will be accessed.
|
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a qualifier from claims for which the (raw) property value matches a given literal value. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets dates in month-day-year order. |
Q55 = "Netherlands", P1082 = "population", P585 = "point in time"
[time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a raw date value. |
Q55 = "Netherlands", P1082 = "population"
[reference] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets the references from a particular claim. |
Q55 = "Netherlands", P1082 = "population"
[reference] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets references from a particular claim in their raw form. |
Q55 = "Netherlands", P1081 = "Human Development Index"
[quantity], [reference] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets properties from each claim with any references they have. |
Q55 = "Netherlands", P1081 = "Human Development Index"
[quantity], [reference] |
Lua error: Internal error: The interpreter exited with status 127.
|
Only gets properties from claims that have at least one reference. |
Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a single qualifier value (for each matching claim). |
Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets multiple qualifier values (for each matching claim). |
Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"
[quantity], [entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets multiple property values along with multiple qualifier values. |
Q55 = "Netherlands", P2855 = "VAT-rate", P518 = "applies to part"
[quantity], [entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Returns the output with custom separators. |
Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"
[entity label], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets two different qualifier values for each claim. |
Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"
[entity label], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Returns the output with a custom separator. |
Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"
[entity label], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Returns the output in a custom format instead of with a custom separator. |
Q55 = "Netherlands", P35 = "head of state", P580 = "start time", P582 = "end time"
[entity label], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
To add text only when a certain value is not present, like adding the word since if there is no end time, wrap it in between two optional blocks containing HTML comment tags and the relevant parameter (this also prevents the text from being added to the page source). |
Q55 = "Netherlands", P35 = "head of state", Q29574 = "Beatrix of the Netherlands", P580 = "start time", P582 = "end time"
[entity label], [time] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a property with qualifiers from claims for which the property matches a given Q-identifier, with one of the qualifier values in its raw form. |
Q55 = "Netherlands", P38 = "currency", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets claims that are currently valid. |
Q55 = "Netherlands", P38 = currency", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets claims with linked property values. |
Q55 = "Netherlands", P38 = currency", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets claims with linked qualifier values. |
Q55 = "Netherlands", P38 = currency", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets claims with linked property and qualifier values, with short property values wherever available. |
Q55 = "Netherlands", P38 = currency", Q4917 = "United States dollar", P518 = "applies to part"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets qualifiers from claims for which the (raw) property value matches a given Q-identifier. |
Q55 = "Netherlands", P38 = currency", P518 = "applies to part", Q27561 = "Caribbean Netherlands"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets properties from claims for which a (raw) qualifier value matches a given Q-identifier. |
Q55 = "Netherlands", P38 = currency"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets claims that were valid in the past. |
Q55 = "Netherlands", P38 = currency"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets raw property values. |
Q55 = "Netherlands", P38 = currency"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets raw property values that are linked to Wikidata. |
Q55 = "Netherlands", P1549 = "demonym"
[monolingual text] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a monolingual text value in the current wiki's language. |
Q55 = "Netherlands", P1549 = "demonym", P407 = "language of work or name", Q36846 = "Toki Pona"
[monolingual text] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a monolingual text value in any available language. |
Q55 = "Netherlands", P2884 = "mains voltage"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a quantity value with its associated unit of measurement. |
Q55 = "Netherlands", P2884 = "mains voltage"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a quantity value with a linked unit of measurement. |
Q55 = "Netherlands", P2884 = "mains voltage"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a raw quantity value. |
Q55 = "Netherlands", P2884 = "mains voltage"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets only the unit of measurement. |
Q55 = "Netherlands", P2884 = "mains voltage"
[quantity] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets the raw unit of measurement. |
Q55 = "Netherlands", P625 = "coordinate location"
[globe coordinate] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a globe coordinate value. |
Q55 = "Netherlands", P625 = "coordinate location"
[globe coordinate] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets a linked globe coordinate value. |
Q55 = "Netherlands", P625 = "coordinate location"
[globe coordinate] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a raw globe coordinate value. |
Q55 = "Netherlands", P625 = "coordinate location"
[globe coordinate] |
Lua error: Internal error: The interpreter exited with status 127.
|
A property alias can be used instead of the P-identifier. |
Q55 = "Netherlands", P41 = "flag image"
[commons media] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets a media file name and links to it on Commons. |
Q55 = "Netherlands", P41 = "flag image"
[commons media] |
Lua error: Internal error: The interpreter exited with status 127.
|
A Commons media file can be included on the page as-is by omitting the linked and raw flags, but by using the raw flag it can be freely formatted.
|
Q55 = "Netherlands", P41 = "flag image"
[commons media] |
Lua error: Internal error: The interpreter exited with status 127.
|
To get the value of a property that was valid at a given time, the date= argument can be used.
|
Q55 = "Netherlands", P41 = "flag image"
[commons media] |
Lua error: Internal error: The interpreter exited with status 127.
|
The time constraint flags work relatively to the date value given for the date= argument.
|
Q915684 = "Lorentz–Lorenz equation", P2534 = "defining formula"
[math] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a mathematical expression. |
Q915684 = "Lorentz–Lorenz equation", P527 = "has part", P416 = "quantity symbol (string)", P2534 = "defining formula"
[entity label], [string], [math] |
<ul>Lua error: Internal error: The interpreter exited with status 127.</ul>
|
Mathematical expressions can be combined with regular text as usual. |
Q6256 = "country", P3896 = "geoshape"
[geographic shape] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets a geographic shape data file name and links to it on Commons. |
Q4917 = "United States dollar"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets an item's label. |
Q4917 = "United States dollar"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets an item's short and linked label. |
P38 = currency"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a property's label. |
P38 = currency"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a property's label that is linked to Wikidata. |
Q776 = "Utrecht"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets an item's label. |
Q776 = "Utrecht"
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets an item's linked label. |
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Utrecht (province) page (which is linked to Q776), then the Q776 can be omitted.
|
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
If just the label command with the raw flag is given, then the Q-identifier of the item connected to the current page is returned.
|
[entity label] |
Lua error: Internal error: The interpreter exited with status 127.
|
If additionally the linked flag is given, then the Q-identifier of the item connected to the current page is linked to Wikidata.
|
Q776 = "Utrecht"
[page title] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets the title of the page on the current wiki that is linked to the given item. |
Q776 = "Utrecht"
[page title] |
Lua error: Internal error: The interpreter exited with status 127. |
Gets the linked title of the page on the current wiki that is linked to the given item. |
[page title] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Utrecht (province) page (which is linked to Q776), then the Q776 can be omitted.
|
Q55 = "Netherlands"
[entity description] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets an item's description. |
[entity description] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Netherlands page (which is linked to Q55), then the Q55 can be omitted.
|
Q55 = "Netherlands"
[entity alias] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets one of an item's aliases. |
Q55 = "Netherlands"
[entity alias] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets all of an item's aliases. |
Q55 = "Netherlands"
[entity alias] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets a linked alias from an item. |
[entity alias] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Netherlands page (which is linked to Q55), then the Q55 can be omitted.
|
Q2 = "Earth"
[page badge] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets the badges for the page on the current wiki that is linked to the given item. |
Q2 = "Earth"
[page badge] |
Lua error: Internal error: The interpreter exited with status 127.
|
Gets the raw badges for the page on the current wiki that is linked to the given item. |
[page badge] |
Lua error: Internal error: The interpreter exited with status 127.
|
If the module is transcluded on the Earth page (which is linked to Q2), then the Q2 can be omitted.
|
Q28865 = "Python", P548 = "version type", P348 = "software version identifier",
[version], [reference] |
Lua error: Internal error: The interpreter exited with status 127.
|
Get Python's latest stable release version with its references. You may want to use P548=Q2122918 to get the lastest preview release version. |
Example references
- ↑ 1.0 1.1 1.2 1.3 1.4 1.5 https://opendata.cbs.nl/statline/#/CBS/nl/dataset/37296ned/table?ts=1560596956049.
- ↑ 2.0 2.1 2.2 http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&LA=NL; retrieved: 26 August 2014.
- ↑ 3.0 3.1 3.2 3.3 http://statline.cbs.nl/StatWeb/publication/?VW=T&DM=SLNL&PA=37296ned&D1=a&D2=0,10,20,30,40,50,60,(l-1),l&HD=130605-0924&HDR=G1&STB=T; retrieved: 22 August 2015; publisher: Statistics Netherlands.
- ↑ 4.0 4.1 http://www.cbs.nl/nl-NL/menu/themas/bevolking/publicaties/artikelen/archief/2016/nederland-telt-17-miljoen-inwoners.htm.
- ↑ 5.0 5.1 https://data.worldbank.org/indicator/SP.POP.TOTL; World Bank Open Data; retrieved: 8 April 2019.
- ↑ 6.00 6.01 6.02 6.03 6.04 6.05 6.06 6.07 6.08 6.09 6.10 6.11 6.12 6.13 http://hdr.undp.org/en/countries/profiles/NLD.
- ↑ 7.00 7.01 7.02 7.03 7.04 7.05 7.06 7.07 7.08 7.09 7.10 7.11 7.12 7.13 7.14 7.15 7.16 7.17 7.18 7.19 7.20 7.21 7.22 7.23 7.24 7.25 7.26 7.27 7.28 7.29 7.30 7.31 7.32 7.33 7.34 7.35 7.36 7.37 7.38 7.39 7.40 7.41 7.42 7.43 7.44 7.45 7.46 7.47 7.48 7.49 7.50 7.51 7.52 7.53 7.54 7.55 http://hdr.undp.org/en/data; Human Development Report.
- ↑ "Python 3.9.1 is now available, together with 3.10.0a3 and 3.8.7rc1". 7 December 2020. https://pythoninsider.blogspot.com/2020/12/python-391-is-now-available-together.html.
Lua error: Internal error: The interpreter exited with status 127.
See also
- {{Wikidata}}, a user-friendly wrapper template for this module.
- {{WikidataOI}}, a wrapper template for this module that adds an opt-in toggle.
- {{Pageid to title}}, to get a page title using its local page id, rather than Wikidata