Hiii,
I am making application for room booking system.
I have a two date textboxes 1.Book from and 2.Book Till
after selecting two dropdown i want to bind dropdown of Room Numbers.
It binds all rooms from MSTROOM table but at the set it should check the booking status of that particulat room from Booking_Details table.
My table structure as belows:
if room num 101 ,102 presents in Booking_Details table with 10 Aug to 11Aug ,11Aug to 13Aug as booking period ,booked status as Booked,Occupied respectively.
Then the remaining rooms from MSTROOM table will display in the dropdown list.
Means the rooms which are booked or occupied status should not bind in the list.
Create Table [MstBook_Status]
(
ID INT IDENTITY(1,1) PRIMARY KEY NOT NULL,
Description NVARCHAR(150) Null
)
Create Table [MstRoom]
(
ID INT IDENTITY(1,1) PRIMARY KEY NOT NULL,
Number NVARCHAR(150) Null,
Price Float ,
Create table Book_Details
(
ID INT IDENTITY (1,1) PRIMARY KEY NOT NULL,
CheckIN_Date DATE NOT Null,
CheckIN_Time Time Null,
CheckOUT_Date DATE NOT Null,
CheckOUT_Time Time Null,
Room_ID INT NOT Null,
Book_Status INT NOT Null,
)
);