Semantic MediaWiki/markup/ask: Difference between revisions

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
No edit summary
No edit summary
Line 6: Line 6:
===Dates===
===Dates===
By default, the filter condition {{fmt/code|{{fmt/arg|property_name}}::{{fmt/arg|property_value}}}} means {{fmt/code|WHERE {{fmt/arg|property_name}} ''equals'' {{fmt/arg|property/value}}}}. Note that {{fmt/arg|property_value}} that is filtering for a date with no time will ''not'' pull up pages where {{fmt/arg|property_value}} is set to a full timestamp in which the time is not 00:00.
By default, the filter condition {{fmt/code|{{fmt/arg|property_name}}::{{fmt/arg|property_value}}}} means {{fmt/code|WHERE {{fmt/arg|property_name}} ''equals'' {{fmt/arg|property/value}}}}. Note that {{fmt/arg|property_value}} that is filtering for a date with no time will ''not'' pull up pages where {{fmt/arg|property_value}} is set to a full timestamp in which the time is not 00:00.
In order to match any timestamp from the same day (00:00 - 23:59)... ''researching this; there are several possible avenues...''
Related:
* <code><nowiki>{{</nowiki>#dateformat:{{fmt/arg|date/time string}}|Y/m/d<nowiki>}}</nowiki></code> will normalize all recognized date-time formats into a YYYY/MM/DD string (time omitted).
==Official Documentation==
==Official Documentation==
* [[smw:Help:Inline queries|Inline queries]]: mostly covers #ask but also #{{l/same|show}} briefly
* [[smw:Help:Inline queries|Inline queries]]: mostly covers #ask but also #{{l/same|show}} briefly

Revision as of 17:02, 6 February 2025

Template:Fmt/title

Syntax

Operators

Dates

By default, the filter condition Template:Fmt/code means Template:Fmt/code. Note that Template:Fmt/arg that is filtering for a date with no time will not pull up pages where Template:Fmt/arg is set to a full timestamp in which the time is not 00:00.

In order to match any timestamp from the same day (00:00 - 23:59)... researching this; there are several possible avenues...

Related:

  • {{#dateformat:Template:Fmt/arg|Y/m/d}} will normalize all recognized date-time formats into a YYYY/MM/DD string (time omitted).

Official Documentation

Operators

Note that there does not seem to be any documentation specifically about available comparison operators. The Template:Fmt/code and Template:Fmt/code operators are mentioned in passing in a couple of places: