I have a view request from a user to create a report that simply shows which of our techs are working or not based on input from the user which is a date range. This is an example of the expected output:
Column 1 Date1 Date2 Date3 Date4 Date5
Employee Name S S A A N
The S equals scheduled, the A equals available, and the N equals not available.
My problem is I am used to building sql views based on Static columns not on data that changes based on user input. Obviously i would be determining the value in each date column based on information in several tables which is tracked by the day with an hour value so that piece should be easy. Any ideas would be much appreciated.