Enable constraint validation only if instances exist.