I have a table tbltask
DateID int
Fromdate int
ToDate int
My question is while inserting date values into database it should not insert if the date is already assigned,
for example,
fromdate todate
2011-05-20 2011-05-29
if i want to insert dates like,
from date todate
2011-05-18 2011-05-30
2011-05-18 2011-05-25
2011-05-20 2011-05-30
2011-05-20 2011-05-30
2011-05-23 2011-05-26 etc
It must not insert
because from 20-29 i have assigned a task but in db i have it as only fromdate and todate