length validation and data model association