문제

How do you add minutes to a DATETIME field?

08/12/2013 11:00:00 PM + 120 minutes
도움이 되었습니까?

해결책

You can just use the add (+) symbol but the value is added in seconds.
120 minutes is 7200 seconds.

NewDateTime = OldDateTime + 7200

Or, for coding clarity as pointed out by Tamar:

NewDateTime = OldDateTime + (120 * 60)
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top