I would envisage a situation the following situation:
1) idProperty is boolean
2) required is string. Example, when required is value of TextBox.
Is it not normal situation? This is validation should be before query?