Author |
Message
|
vadivel |
Posted: Tue Dec 11, 2012 7:52 am Post subject: Renaming file in Target System |
|
|
 Voyager
Joined: 05 Aug 2002 Posts: 79 Location: US
|
Hi,
Is there a way to rename a file in the target system with datetimestamp suffix using Transfer definition file.
For ex: Source file name is purchaseorder_201212010102120003.dat and Target file name should be PO_<YYYYMMDDHHMISSssss>.dat with the date time being the time at which the file was delivered in the target applications.
Regards |
|
Back to top |
|
 |
bruce2359 |
Posted: Tue Dec 11, 2012 8:48 am Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
What does the file-transfer command documentation say about filenames? _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
vadivel |
Posted: Thu Dec 13, 2012 2:50 am Post subject: |
|
|
 Voyager
Joined: 05 Aug 2002 Posts: 79 Location: US
|
I couldnt find much help with documentation.. All I can see if -df option can be used to specify the file name.. but my requirement is to dynamically construct the file name based on the datetime the file is actually delivered.[/quote] |
|
Back to top |
|
 |
bruce2359 |
Posted: Thu Dec 13, 2012 6:11 am Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
I'm thinking that you could create a batch script that makes use of the date/time provided by your o/s's environment variables. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
vadivel |
Posted: Mon Dec 17, 2012 1:40 am Post subject: |
|
|
 Voyager
Joined: 05 Aug 2002 Posts: 79 Location: US
|
In general, I have some concerns about the post processing scripts to rename the file after the transfer is successful..
If there is an option using which FTE transfer process itself can write the file in the required name, it would be good.. But I guess this feature is still not yet in the product.. |
|
Back to top |
|
 |
nickla23 |
Posted: Mon Feb 11, 2013 7:01 am Post subject: |
|
|
Novice
Joined: 06 Dec 2012 Posts: 12
|
Not sure of your exact business process, but if you used a Resource Monitor to trigger the transfer you can pull in the datetimestamp and format it to your needs with variable substitution.
Otherwise, like Bruce said you will need to do some post-transfer scripting to achieve this. |
|
Back to top |
|
 |
|