Validation and behavior of date