Help:Property constraints portal/Diff within range/ru
<languages/> Help:Property constraints portal/Header constraint type

Ограничение «Template:Q» определяет, что разница между значениями двух свойств должна находиться в пределах определённого диапазона или интервала. Это ограничение доступно для свойств количества или даты.
Например, разница между значениями свойств Template:P и Template:P должна быть положительной, но не более 150 лет: то есть должна лежать внутри иинтервала .
WikibaseQualityConstraints normalizes the range endpoints before checking this constraint; for example, the intervals and are equivalent.
Если Template:P не определена, это ограничение проверяется только для основного значения элемента. Это также единственная поддерживаемая в настоящее время область.
Возможные действия
На нарушение этого ограничения можно реагировать одним из следующих способов:
- Возможно, в содержащем ограничение утверждении указано неверное значение, которое должно быть исправлено.
- Возможно, в другом утверждении содержится неверное значение, которое должно быть исправлено.
- Возможно, одно из двух утверждений должно быть полностью удалено.
- Возможно, этот элемент представляет собой редкое, но законное исключение из этого ограничения, и ничего делать не требуется.
Параметры
У этого ограничения три обязательных параметра:
- Template:P
- Contains the related property. Must contain exactly one property (Template:No value or Template:Unknown value is not permitted), which must have the same data type as the property on which the constraint is placed. The difference is calculated as the value for the property with the constraint minus the value for the property given in this parameter, so usually the constraint is placed on the “upper” property (e. g. Template:P), and the parameter specifies the “lower” property (e. g. Template:P).
- Template:P
- The lower boundary of the permitted range. The unit of the boundary value should match the unit of the two properties (e. g. Template:Q for Template:P and Template:P). Template:No value can be used to specify a range with no lower boundary (). Template:Unknown value is not permitted.
- Template:P
- The upper boundary of the permitted range. The unit of the boundary value should match the unit of the two properties (e. g. Template:Q for Template:P and Template:P). Template:No value can be used to specify a range with no upper boundary (). Template:Unknown value is not permitted.
Example
Example setting for Template:P. Template:Statement+
Template
When the constraint is set to the property, the following template is automatically displayed in the property talk page. The template is created by Module:Constraints using Template:Constraint, invoked from Template:Property documentation. Translations are defined at Module:i18n/constraints.
{{#invoke:Constraints|extractIndividualConstraintTemplate|id=P570|constraint_type=Q21510854}}
Lists
Lists of properties which are set difference within range constraint.
Template:Property constraints
Template:Translation categories