Hello everyone,
i have a problem with the subtracting a DATETIME column with todays DATETIME.
One of the columns has the HireDate
(Date of hiring a certain employee). I want to know how many Years they are employed.
事先感谢你!
我尝试:
SELECT LastName, HireDate, DATE( now ), DATE( now - HireDate)
FROM employees
或
SELECT LastName, HireDate, DATE( now ), DATE(DATE( now - HireDate)
FROM employees
I expected: The diffrence, so the time they were hired at the company I got: negative numbers...