FTP TASK

  • Hi

    I am creating a flat file (destination) in ssis with the naming convention (bh5601_yyyymmddhhmmss.bdf). Each day a file is created with different name.

    I am using the following expression in the flatfile connection manager proerty box to give dynamic name to the file.

    "C:\\Users\\Downloads\\bh5601_"+(DT_STR,4,1252)DATEPART( "yyyy" , @[System::StartTime] ) +

    RIGHT("0" + (DT_STR,4,1252)DATEPART( "mm" , @[System::StartTime] ), 2) +

    RIGHT("0" + (DT_STR,4,1252)DATEPART( "dd" , @[System::StartTime] ), 2) +

    RIGHT("0" + (DT_STR,4,1252)DATEPART( "hh" , @[System::StartTime] ), 2) +

    RIGHT("0" + (DT_STR,4,1252)DATEPART( "mi" , @[System::StartTime] ), 2) +

    RIGHT("0" + (DT_STR,4,1252)DATEPART( "ss" , @[System::StartTime] ), 2)+".bdf"

    It is working well. Now after the file is ctrated, i am using the FTP task to pick up that particular file and sent to remote path. I am able to configure the remote path but can any body telll me how to make local path dynamic.

    Flat file is created everyday. so i want ftp task to pick up file with correct datetime stamp.

    Please help.

    Thanks

  • You should either be able to use a variable for the local path attribute, or build an expression for it. Either one should do what you need.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • You can try to use NET USE command to batch file and try

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

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