Looks like the data was born ugly. InDate should be the date when the guy started working.
Then again, data did not look this day when you asked about dynamic pivot, for which I gave you a query. And, yes, I did consider the situation of an over-night shift. From the data model you presented at that time.
Did you redesign the data model the last few days, or why is this different?
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
No comments:
Post a Comment