Yes this is possible.
First note that there is also the native ${/CORE_BEGIN_DATE}$ session variable, which provides this format: 2016/06/29 09:42:59.848
If you need a specific format, then apply a Rhino date formatting function.
For this, you can create a Variable which will be re-usable in all your developments.
For example:
- Create a Variable Metadata, named "CURRENT_SESSION_DATETIME"
- The default value will be this Rhino expression:
%e(rhino){ java.text.SimpleDateFormat("yyyyMMdd-HHmmss.SSS").format(new Date(${/CORE_SESSION_TIMESTAMP}$)) }e(rhino)%
See
SimpleDateFormat Reference
to know how to specify your desired format.
- Then use this variable in your file name, e.g. "MyFile_%{CURRENT_SESSION_DATETIME}%"
Don't forget to drag and drop the variable into your processes and mappings where you need it.