Manish Solanki

Manish Solanki

  • NA
  • 77
  • 25.5k

compare two date from two table in sqlserver

Oct 27 2015 3:31 AM
Hello Everyone
I have two table..
1. Holiday
 -HolidayId
 -Description
 -HolidayDate
 - Status
 
2. EmployeeLeaves
 - LeaveId
 -EmployeeId
 -RequestedDate
 -LeaveReason
 -LeaveFrom
 -LeaveTo
 -LeaveStatus
   now when employee apply for the leave that time the HolidayDate will be compare with leaveFrom and LeaveTo date.
 suppose sir,  11/11/2015 is holiday this is allready in Holiday table. now when employee apply for the same date for leave that time it will alert message is printed "you can not apply for this day this is already holiday".I want this kind of output.
can please help for this for procedure and apply in aspx page. 
 

Answers (3)