Template:Define recency constraint
Jump to navigation
Jump to search
Please note that this template must be substituted. Replace {{define recency constraint}} with {{subst:define recency constraint}} .Check un-substituted usage |
Recency
point in time (P585)-qualifier of values shouldn't be older than the duration set at Property:P1128#P1552 with complex constraint recency (Q102173107) (Help)
Violations query:
List of this constraint violations: Database reports/Complex constraint violations/Define recency constraint#Recency
point in time (P585)-qualifier of values shouldn't be older than the duration set at Property:P1128#P1552 with complex constraint recency (Q102173107) (Help)
Violations query:
SELECT ?item ?dt ?age_days ( ROUND((now() - ?dt) / ?factor ) as ?age) WHERE { hint:Query hint:optimizer "None". wd:P1128 p:P1552 [ ps:P1552 wd:Q102173107 ; pq:P2047 ?duration ; pqv:P2047 / wikibase:quantityUnit ?unit ] . ?unit p:P2442 / psv:P2442 [ wikibase:quantityUnit wd:Q573 ; wikibase:quantityAmount ?factor ] BIND(?duration * ?factor as ?maxagedays) ?item p:P1128 ?st . ?st pq:P585 ?dt . FILTER NOT EXISTS { ?item p:P1128 / pq:P585 ?dt0 . FILTER( ?dt0 > ?dt) } ?st ps:P1128 ?value . BIND( ROUND(now() - ?dt) as ?age_days) FILTER( ?age_days > ?maxagedays) FILTER NOT EXISTS { ?item wdt:P576 [] } FILTER NOT EXISTS { ?item wdt:P3999 [] } FILTER NOT EXISTS { ?item wdt:P582 [] } FILTER NOT EXISTS { ?item wdt:P570 [] } } LIMIT 500
List of this constraint violations: Database reports/Complex constraint violations/Define recency constraint#Recency
Defines {{Complex constraint}}
on property talk pages for properties with complex constraint recency (Q102173107).
Usage
[edit]{{subst:Define recency constraint}}
See also
[edit]The above documentation is transcluded from Template:Define recency constraint/doc (edit | history). Editors can experiment in this template's sandbox (create | mirror) and testcases (create) page. Please add categories to the /doc subpage. Subpages of this template. |