How do I strip the date off of a datetime string in SQL SSIS?

前端 未结 5 652
情话喂你
情话喂你 2020-12-20 23:49

I\'m working on a data warehouse project and would like to know how to (preferably in a Derived Column component in a Data flow) strip the date piece off of a SQL datetime r

5条回答
  •  -上瘾入骨i
    2020-12-21 00:14

    I would just do a cast to DT_DBTIME type (using Derived Column transform, or Convert type transform). DT_DBTIME contains just (hours, minutes, seconds) part of the date/time, so you'll get rid of the date part.

提交回复
热议问题