Listing 3: Creation Script for the VStartEndCalls View CREATE VIEW VStartEndCalls AS SELECT username, calldate AS firstminute, DATEADD(minute, duration - 1, calldate) AS lastminute, -- difference between date of call and base date 19000101 in days: DATEDIFF(day, '19000101', calldate) AS diff FROM Calls