In SQL Server, I’m dealing with these columns:
tblSchedule
ID
StaffID
StartTime
EndTime
I want to include a boolean field in my result set that indicates whether StartTime and EndTime are equal. Something analogous to this:
SELECT StaffID, StartTime, EndTime, (StartTime = EndTime) AS AreEqual
FROM tblSchedule Where StaffID = xxx
But I’m not sure of the actual syntax for an operation like that.
I think this is what you are looking for