How to validate an entry