How to put validation to date : [![enter image description here][1]][1]


  [1]: https://i.stack.imgur.com/exKZ1.png


Student can select any number of CourseBatchCode,

in Case 3 CourseBatchCode is selected 
This is my Table I want to put validation on the table that


1)ENDTIME should not be between following Start time and end time

2)EndTime should be less than following Start Time and End time

Plz Help with Cursor Query thank u