Trying to Add New Lines to a Derived Column Task

  • Guys,

    I'm using the following expression to derived a column. I need to add line breaks. Books online says to use the "/n" to do this, but it doesn't seem to be working. Any words of wisdom here?

    Here is my Express (Derived Column Name = Header_Append_Full):

    (DT_WSTR,32)"X-sCRM_CustomerID: " + (DT_WSTR,32)SCRM_CustomerID + (DT_WSTR,32)"" + (DT_WSTR,32)"X-sCRM_OpportunityID: " + (DT_WSTR,32)SCRM_OpportunityID + (DT_WSTR,32)"" + (DT_WSTR,32)"X-sCRM_EmployeeID: " + (DT_WSTR,32)SCRM_EmployeeID + (DT_WSTR,32)""

    Here is an example of my expected results:

    X-sCRM_CustomerID: 592

    X-sCRM_OpportunityID: 726

    X-sCRM_EmployeeID: 16

    I have another Derived Task immediately after the one in question which concatenates the three above columns with an email header and email body. It looks like this:

    (DT_TEXT,1252)EmailHeader + (DT_TEXT,1252)" " + (DT_TEXT,1252)Header_Append_Full + (DT_TEXT,1252)NoteText

    The idea here is to reconstruct a RFC formatted header using database fields and add the three new tags referenced in the Header_Append_Column to allow our email system to tie individual email messages to employees, customers, and opportunities. I have uploaded a txt file of what I would want the full txt file look like in an ideal world. The last task is an Export Column task to create txt files. On the example header if you scroll to the very bottom you will see examples of the header tags I'm trying to add.

  • Did you try the forward slash, instead?

    ---
    SSIS Tasks Components Scripts Services | http://www.cozyroc.com/

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply