Date checking in mysql -- date and time duration


my table has


both dates are in date type and starttime and endtime are in time type.

I want to check if my data consisting of startdate,starttime,enddate,endtime cannot be present in table and must be a valid date and time duration.

How to check this valid date and time interval?

my problem was

Duration of startdate with starttime and enddate with endtime can’t be repeat or override or not inbetween in table,

It must be a valid interval for sale a particular product.

I need mysql query to do this.


Ramakrishnan t