SQL query to insert available slots into a table (avail) from reserved table slots

I want a sql query to insert the available slots into the table (avail) from the reserved slots.

I have two tables. I have a table of books with bookstarttime and bookendtime columns. These are temporary objects. I have another table with availstarttime and availendtime.these are also timestamp columnss.I i need to get the available slots remaining between these booked slots.I will enter start time and end time from the form. Then I want the sql query to get the available slots between the start time and end time values

I am using database: apache derby

+1


a source to share


1 answer


You can check out a very similar question given below.

Also, as Tomalak said, you almost certainly don't want to keep two copies of the same data in your database. Perhaps add a view that gives you a different perspective on the data, but don't keep two copies of the same information because it will almost certainly become conflicting.



Similar question: Searching for free slots in the booking system

+1


a source







All Articles