Results 1 to 3 of 3

Thread: Creating file name dynamically while writing.

  1. #1
    Join Date
    May 2009
    Posts
    21

    Default Creating file name dynamically while writing.

    We have a scenario where we have to write the data to a File. Presently we are using FlatFileItemWriter in order to write data to flat file using xml tag. PFA snippet from our xml file.


    Where <beansroperty name="resource" value="${outputFile.Path}"/>

    Represents the destination file where data will be written.
    is there a way to change the destination file name dynamically instead of reading from property file. E.g. Each and every time a writer is called a new file should be created with dat/time appended to it.
    Attached Files Attached Files

  2. #2
    Join Date
    Feb 2008
    Posts
    488

    Default

    You should use the late binding feature: http://static.springsource.org/sprin...l#late-binding

  3. #3
    Join Date
    May 2009
    Posts
    21

    Default

    Thanks for the reply. Issue got solved with this late binding feature.

Posting Permissions

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