TMACUL

CA SDM::. Como converter data para o formato Brasileiro no MS SQL?

Blog Post created by TMACUL Champion on Feb 23, 2017

CA SDM::. How to convert CA Format date -  Unix epoch time - seconds date? 

 

select convert(varchar(25), DATEADD(ss, open_date, '19700101'),113) 
from call_req

Exemplo de resposta: "12 Set 2002 19:00:00:000"

 

select convert(varchar(10), DATEADD(ss, open_date, '19700101'),103) + ' ' +
convert(varchar(8), DATEADD(ss, open_date, '19700101'),114)
from call_req

Exemplo de resposta: "12/09/2002 19:00:00"

 

 

CAST e CONVERT (Transact-SQL) 

Outcomes