String text = descr.getText();
Variable variable = data.getVariableByRuleAndVariableName(currentRule
.getRuleName(), text.substring(0, text.indexOf(".")));
QualifiedIdentifierRestriction restriction = new QualifiedIdentifierRestriction();
restriction.setRuleId(currentRule.getId());
restriction.setPatternId(currentPattern.getId());
restriction.setPatternIsNot(currentPattern.isPatternNot());
restriction.setConstraintId(currentConstraint.getId());
restriction.setFieldId(currentConstraint.getFieldId());
restriction.setEvaluator(descr.getEvaluator());
restriction.setVariableId(variable.getId());
restriction.setVariableName(text.substring(0, text.indexOf(".")));
restriction.setVariablePath(text.substring(text.indexOf(".")));
// Set field value, if it is unset.
currentField.setFieldType(Field.FieldType.VARIABLE);
variable.setObjectType(AnalyticsComponentType.FIELD);