Pergunta

Estou tentando usar Datediff Para descobrir a duração entre columnA e columnB.

SELECT datediff (minute, stime, etime)
from Exceptions2
where stime = [exceptions2].starttime
and etime = [exceptions2].endtime

Isso produz erros. Alguém pode me ajudar com o que estou fazendo de errado?

Foi útil?

Solução

Que tal tentar isso, não sei por que você tem stime = [exceções2] .StartTime e Etime = [Exceções2] .TimeTime

SELECT datediff(minute, starttime, endtime) from Exceptions2
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top