How can I SSIS Concatenate DTS.Variables in Script Task or anywhere?

  • How can I SSIS Concatenate DTS.Variables in Script Task?

    sDateTimeStamp = sMonth & sDay & sYear & sHour & sMinute & sSecond

    Dts.Variables("DateTimeStamp").Value = sDateTimeStamp

    sFilePath = "F:\SQLXXX-S01-BAK-F5a\MSSQLI\Backups\ETL\QQQ_Reports\ADR_BB_J9\Reports\"

    sFilePrefix = "ReportsPETS_XX_WW_DailyCount"

    sDateTimeStamp = sMonth & sDay & sYear & sHour & sMinute & sSecond

    sFileSuffix = ".csv"

    Dts.Variables("gsFileName").Value = sFilePath & sFilePrefix & sDateTimeStamp & sFileSuffix

    'Dts.Variables("gsFileName").Value = Dts.Variables("gsFilePath").Value & Dts.Variables("FilePrefix").Value & Dts.Variables("DateTimeStamp").Value & Dts.Variables("FileSuffix").Value

    For better, quicker answers on T-SQL questions, click on the following...
    http://www.sqlservercentral.com/articles/Best+Practices/61537/

    For better answers on performance questions, click on the following...
    http://www.sqlservercentral.com/articles/SQLServerCentral/66909/

  • Duplicate post. The question is being answered here.

    ---
    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