0

I want to convert the number in BigInt format to the Date format in SSIS, can anyone please help me to get out of it. I apply below code but it does not work for me

DATEADD("SECOND",CreatedAt / 1000,(DT_DBTIME)"1/1/1970")
Yahfoufi
  • 2,220
  • 1
  • 22
  • 41

1 Answers1

0

You are having DT_DBTIME. Instead, you should be having DT_DBDTIMESTAMP. It is the one corresponding to Datetime

DATEADD("second",(DT_I8)createdAt/1000,(DT_DBTIMESTAMP)"1/1/1970")

CreatedAt = 2000
DATEADD("second",(DT_I8)createdAt,(DT_DBTIMESTAMP)"1/1/1970") => 1970-01-01 00:00:02

Venkataraman R
  • 12,181
  • 2
  • 31
  • 58