locked
Receive File in Dynamic folder inside biztalk RRS feed

  • Question

  • Hi,

    i came across a requirement in which each time i am gettting a folder (DDMMYYHHMMSS_tradeNumber )in this format.And under this folder i am getting a .csv file.

    Attribute of dynamic folder are:

    Unique datetime and unique trade number.

    So my requirement is to process .csv file into biz talk without deletion of the dynamic folder.

    Example   c:\fixedfolder\DynamicFolder\Sample.csv

    Please Suggest.

    Thanks

    Piyush

    Wednesday, April 20, 2016 4:52 PM

Answers

  • Hi Piyush,

    Thank you for posting on MSDN forum.

    You can achieve your scenario with the help of powershell script.

    Create some script that will move your .csv to some other folder location and you can use here Task Scheduler.

    Configure the folder location with receive location. 


    Thanks,

    If my reply is helpful please mark as Answer or vote as Helpful.

    My blog | Twitter | LinkedIn

    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

    • Proposed as answer by Angie Xu Friday, May 6, 2016 2:28 AM
    • Marked as answer by Angie Xu Friday, May 6, 2016 2:28 AM
    Wednesday, April 20, 2016 6:48 PM
    Moderator

All replies

  • Hi Piyush,

    Thank you for posting on MSDN forum.

    You can achieve your scenario with the help of powershell script.

    Create some script that will move your .csv to some other folder location and you can use here Task Scheduler.

    Configure the folder location with receive location. 


    Thanks,

    If my reply is helpful please mark as Answer or vote as Helpful.

    My blog | Twitter | LinkedIn

    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

    • Proposed as answer by Angie Xu Friday, May 6, 2016 2:28 AM
    • Marked as answer by Angie Xu Friday, May 6, 2016 2:28 AM
    Wednesday, April 20, 2016 6:48 PM
    Moderator
  • Hello Piyush,

    To achieve this you have to implement a process of creating receive locations dynamically.

    You can review this post by Brian Loesgen called Bootstrapping BizTalk: Dynamically creating receive locations.

    Rachit Sikroria (Microsoft Azure MVP)

    Thursday, April 21, 2016 8:18 AM
    Moderator
  • It is not possible to use a dynamic receive location using out of the box adapter in BizTalk.

    I think what you need is to have Windows Schedule Task that run a PowerShell or console application

    to read all files inside parent folder and move them to single folder where a BizTalk receive location reads from only one folder.



    When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer

    Thursday, April 21, 2016 11:29 AM
  • Hi Piyush,

    As already suggested in many answers, u can use any one of the desired way of doing the same.

    Just to add, if ur location can be set up as ftp or sftp, then a third part adapter set - nsoftware , does support dynamic receive location configuration that works on date , time etc. They also support downloading a file using a send ftp or sftp port. This is just an FYI as it relates to dynamic receiving.

    For ur case, what i see best suits is a powershell that moves ur files to biztalk receive. 

    PS. nsoftware has a powershell adapter as well that u can use to trigger scripts. :)


    When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer

    Thursday, April 21, 2016 12:49 PM
    Answerer
  • The best way to handle this is to contact the owner of the other system and get them to change this unnecessarily complicated pattern.  Just put the meta data in the file name.

    If they can't or won't, then the best way for you to handle this is with a PowerShell script that checks the dynamic folder and moves the file to a static folder where BizTalk is watching.  Such a file operation with PowerShell is quite trivial.

    You would run the script using the Windows Task Scheduler.  This is a perfectly legitimate BizTalk pattern.

    Sunday, April 24, 2016 8:54 PM
    Moderator