Validation and pagination