Fields when entered needs to be validated

hi guys

Thanks for the support you give

I have some four fields which is not mandatory, but when that field is entered need to be validated before saved


it can take null value

can you please guide me

Have a look at the rails guide on validations,



Thank you