Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2013

    Unanswered: SSIS Derived Column


    Two questions regarding Derived Columns in SSIS

    1. In a if else expression if condition is false how do you keep the value of the source column eg: Name == "" ? "Unknown" : Name
    Above will change all the non blank values to Name and not the actual value
    in the Name Column eg. John

    2. I have a column (unicode string)that stores date and time (The source is flat file) Is it possible to write expression to select the 1st day of month based on that date, and use this derived column as input to a table with a datetime field.

    Thank You

  2. #2
    Join Date
    Feb 2004
    In front of the computer
    Provided Answers: 54
    Do the conversions on the SQL side of SSIS (as expressions).
    1. CASE WHEN myCol = '' THEN 'Unknown' ELSE myCol END
    2. DateAdd(m, DateDiff(m, 0, myCol), 0)
    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts